Gait producing device for leg type movable robot

ABSTRACT

A desired gait is generated so as to satisfy a dynamical equilibrium condition concerning the resultant force of gravity and an inertial force applied to a legged mobile robot  1  using a dynamics model which describes a relationship among at least a horizontal translation movement of a body  24  of the robot  1 , a posture varying movement in which the posture of a predetermined part, such as the body  24 , of the robot  1  is varied while keeping the center of gravity of the robot  1  substantially unchanged and floor reaction forces generated due to the movements and is defined on the assumption that a total floor reaction force generated due to a combined movement of the movements is represented as a linear coupling of the floor reaction forces associated with the movements. The dynamics model represents movements as a movement of a body material particle or the like and a rotational movement of a flywheel. The desired gait adapted for not only walking but also running or the like can be generated with a reduced amount of calculation.

TECHNICAL FIELD

The present invention relates to a gait generation device that issuitable not only for walking of a legged mobile robot but also forrunning.

BACKGROUND ART

Conventionally, generation of a gait (desired gait) for causing a leggedmobile robot, for example, a two-legged mobile robot to move hasprimarily been aimed to generate a gait (walking gait) which causes therobot to perform a smooth walking action. However, in recent years, asthe development of the legged mobile robot has been advanced, it isdesired to generate a gait that can cause the robot not only to walk butalso run.

Note that, since the word “gait” in Chinese characters includes aChinese character meaning “walk”, the word tends to be misunderstood asmeaning only walking. However, originally, the word “gait” has a conceptthat also includes “running” as evidenced by the fact that it is used asa word for “trotting” or a running mode of a horse.

Here, a difference between characteristics of walking and running willbe described.

It is a general practice to define a moving mode, in which there is aninstance when all the legs are in the air simultaneously, as running.However, walking and running are not always distinguished clearly bythis definition. For example, whereas, in fast jogging, most people findan instance when all the legs are in the air, in slow jogging,relatively large number of people find one of the legs is always incontact with the ground. It is slightly unreasonable perceptually todefine that, while fast jogging is running, slow jogging is walking.

FIG. 48 shows a pattern of a body vertical position and a floor reactionforce's vertical component (a sum of floor reaction force's verticalcomponents acting on both the left and right legs) in typical running.FIG. 49 shows a pattern of a body vertical position and a floor reactionforce's vertical component in typical walking.

Note that a body vertical position/velocity means a vertical position ofa body representative point and a velocity thereof. A body horizontalposition/velocity means a horizontal position of the body representativepoint and a velocity thereof. The body vertical position/velocity andthe body horizontal position/velocity are collectively referred to as abody position velocity.

In addition, a “floor reaction force's vertical component” should bemore precisely described as a “vertical component of the translationfloor reaction force” in order to distinguish it from a moment componentaround a vertical axis of a floor reaction force. However, since theword is lengthy, “translation” is omitted here.

First, considering a movement of a body, during walking, the body is atthe highest position at an instance when the body passes over asupporting leg and, during running, the body is at the lowest positionat this instance. That is, a phase of a vertical motion pattern of thebody is inversed during walking and running.

On the other hand, the floor reaction force is relatively constantduring walking, while it fluctuates significantly and reaches themaximum at an instance when the body passes over the supporting legduring running. In addition, naturally, the floor reaction force is 0 atan instance when all the legs are in the air simultaneously. Morespecifically observed, during running, a floor reaction force of amagnitude generally proportional to an amount of drawing-in of thesupporting leg is generated. In other words, during running, it can besaid that a person is moving while using legs like springs to jump.

Slow jogging has the same phase of a body vertical movement as thetypical running. In addition, in slow jogging, although there is almostno instance when all the legs are in the air simultaneously, even inthat case, a floor reaction force is substantially 0, although notcompletely 0, at an instance when a supporting leg and a free leg areswitched.

Therefore, it could be more appropriate to distinguish walking andrunning from the above-described characteristics of the patterns of avertical movement of the body and the floor reaction force as describedabove because slow jogging is regarded as running, which coincides withperception.

In particular, if running and walking are distinguished in a mostcharacteristic point, it could be said that running is a moving mode inwhich a floor reaction force is 0 or substantially 0 at an instance whena supporting leg is switched, and waling is the other moving modes (inwhich a floor reaction force's vertical component is relativelyconstant).

In Japanese Patent Application No. 2000-352011, the applicants havealready proposed a technique for generating a legged mobile robot's gaitinvolving a floor reaction force in a flexible manner in real time whilesubstantially satisfying a dynamical equilibrium condition (thedynamical equilibrium condition is a balance condition among thegravity, inertial force and floor reaction force for a desired gait. Ina narrow sense, the condition is that the moment applied about thedesired ZMP by the resultant force of gravity and the inertial forcecaused by the movement of the desired gait is 0. Details thereof will bedescribed later). In this case, fundamentally, the movement of an endportion of each leg is determined, the vertical position of the body isdetermined based on a geometrical condition, and then, the horizontalmovement of the body is determined so as to satisfy the dynamicalequilibrium condition. This technique and a series of control devicesfor legged mobile robots proposed by the applicants in Japanese PatentLaid-Open Nos. 10-86081 and 10-277969 and the like can be applied notonly walking but also running.

In particular, for example, for a running gait including a period inwhich all the legs of the robot float in the air or a period in which asufficient translation floor reaction force cannot be generated (thatis, immediately before taking off the floor or immediately afterlanding) or for a gait with which the robot moves on a surface having alow friction coefficient, the rotational movement of the robot about thecenter of gravity is important to generate adequately the gait so as tosatisfy the dynamical equilibrium condition.

However, according to the technique described above, the desired gait isgenerated essentially on the assumption that the body posture is keptunchanged, and thus, the dynamics model used for generating the desiredgait does not sufficiently take into consideration the effect of thefloor reaction force involved in a rotational movement, such as a changeof body posture. Thus, there is a possibility that the gait which allowsadequate running or other movement of the robot cannot be generated.

In this case, if a precise dynamics model of the robot is used, anadequate gait can be generated. However, using such a precise modelresults in a higher nonlinearity, so that the amount of calculationinvolved in determination of the desired gait that satisfy the dynamicalequilibrium condition increases significantly. Therefore, it isdifficult to generate in real time a gait for the robot to move at ahigh velocity, such as a running gait.

Therefore, an object of the present invention is to provide a gaitgeneration device that can generate a gait for a legged mobile robotwhich is suitable for not only walking of the robot but also running orother movement at a high velocity.

More specifically, an object of the present invention is to provide agait generation device that can generate in real time a gait whichallows robot movements including walking and running without any troublewithout using a complicated dynamics model.

DISCLOSURE OF THE INVENTION

A gait generation device for a legged mobile robot according to thepresent invention is a gait generation device for generating a desiredgait for a legged mobile robot that moves by operating a plurality oflegs extending from a body, characterized in that the desired gait isgenerated so as to satisfy a predetermined dynamical equilibriumcondition concerning the resultant force of gravity and an inertialforce applied to the robot using a dynamics model which describes arelationship among at least a horizontal translation movement of thebody, a posture varying movement in which the posture of a predeterminedpart of the robot is varied while keeping the center of gravity of therobot substantially unchanged and floor reaction forces generated due tothe movements and is defined on the assumption that a total floorreaction force generated due to a combined movement of the movements isrepresented as a linear coupling of the floor reaction forces associatedwith each of the movements (first implementation).

According to the first implementation, the dynamics model represents thetotal floor reaction force generated due to the combined movement of theposture varying movement and the body horizontal movement as a sum ofthe floor reaction forces due to the movements. Thus, the linearity ofvariation of the floor reaction force with each movement is enhanced.Thus, a set of the body horizontal translation movement and the posturevarying movement that satisfies the dynamical equilibrium conditionconcerning the resultant force of the inertial force and gravityproduced due to each movement and, thus, the body horizontal positiontrajectory and the posture trajectory of the predetermined part can bedetermined with a reduced amount of calculation. Furthermore, since thecenter of gravity kept is substantially unchanged in the posture varyingmovement involved in the dynamics model, the posture varying movementproduces a floor reaction force moment while keeping the translationfloor reaction force (or translation inertial force) almost unchanged.Therefore, even for running, walking on a floor having a low frictionalcoefficient or other movements for which the translation floor reactionforce to be produced is limited, a gait that satisfies the dynamicalequilibrium condition can be generated by adjusting the body posturevarying movement.

Thus, according to the first implementation, a gait which allows robotmovements including walking and running without any trouble can begenerated in real time without using a complicated dynamics model. Thatis, a gait suitable for not only walking of the robot but also runningor other movement at a high velocity can be generated.

The dynamics model according to the first implementation represents arelationship among at least the horizontal translation movement of thebody, the posture varying movement and floor reaction forces generateddue to the movements. However, besides the horizontal translationmovement of the body and the posture varying movement, it may involve amovement of an end portion of each leg (second implementation) andfurther involve a vertical translation movement of the body (thirdimplementation). More specifically, according to the secondimplementation, the desired gait is generated so as to satisfy apredetermined dynamical equilibrium condition concerning the resultantforce of gravity and an inertial force applied to the robot using adynamics model which describes a relationship among at least a movementof an end portion of each leg, a horizontal translation movement of thebody, a posture varying movement in which the posture of a predeterminedpart of the robot is varied while keeping the center of gravity of therobot substantially unchanged and floor reaction forces generated due tothe movements and is defined on the assumption that a total floorreaction force generated due to a combined movement of the movements isrepresented as a linear coupling of the floor reaction forces associatedwith each of the movements.

Furthermore, according to the third implementation, the desired gait isgenerated so as to satisfy a predetermined dynamical equilibriumcondition concerning the resultant force of gravity and an inertialforce applied to the robot using a dynamics model which describes arelationship among at least a movement of an end portion of each leg, ahorizontal translation movement of the body, a vertical translationmovement of the body, a posture varying movement in which the posture ofa predetermined part of the robot is varied while keeping the center ofgravity of the robot substantially unchanged and floor reaction forcesgenerated due to the movements and is defined on the assumption that atotal floor reaction force generated due to a combined movement of themovements is represented as a linear coupling of the floor reactionforces associated with each of the movements.

In the second implementation, the same effects and advantages as in thefirst implementation are provided, and the approximation precision ofthe dynamics model is improved because the dynamics model involves themovement of the end portion of each leg. As a result, the desired gaitthat satisfies the dynamical equilibrium condition with a higherprecision can be generated. In the second implementation, for example,if the movement of the end portion of each leg is determined based on arequired value of a landing position/posture or landing time of the endportion or the like independently of the dynamical equilibriumcondition, the desired gait that satisfies the dynamical equilibriumcondition can be more readily generated.

In the third implementation, the same effects and advantages as in thefirst implementation are provided, and the approximation precision ofthe dynamics model is further improved because the dynamics modelinvolves the movement of the end portion of each leg and the verticalmovement of the body. As a result, the desired gait that satisfies thedynamical equilibrium condition with a still higher precision can begenerated. In the third implementation, for example, it is preferablethat the movement of the end portion of each leg is determinedregardless of the dynamical equilibrium condition as describedconcerning the second implementation, and the vertical movement of thebody (that is, the vertical position trajectory of the body) isdetermined based on a predetermined geometrical condition concerningdisplacement of a joint of each leg (preferably when generating awalking gait) or depending on the vertical component of a desired floorreaction force or the vertical component of a total center-of-gravityacceleration of the robot (preferably when generating a running gait).Thus, the desired gait that satisfies the dynamical equilibriumcondition can be more readily generated, and the generated desired gaitcan be more adequate for the mode of the gait to be generated.

In the first to third implementation, it is preferable that the gaitgeneration device comprises means for setting a desired ZMP of therobot, wherein the dynamical equilibrium condition is a condition that amoment produced about the desired ZMP by a movement with the desiredgait is substantially 0 (fourth implementation). This allows a desiredgait with which the robot can move with a high stability to begenerated. Alternatively, the dynamical equilibrium condition may be onethat the above-described resultant force is brought into balance withthe floor reaction force for a particular component.

Besides, in the first to fourth implementation, the predetermined partis preferably the body of the robot (fifth implementation). That is,since, in general, the body of the robot is relatively heavy, a changeof posture of the body tends to cause a change of floor reaction forcemoment. Therefore, even if a sufficient translation floor reaction forcecannot be generated (for example, when all the legs float in the airduring running), a desired gait that satisfies the dynamical equilibriumcondition can be generated while preventing the robot from significantlyvarying its movement as a whole.

Furthermore, in the first implementation, it is preferable that thedynamics model represents the horizontal translation movement of thebody as a horizontal translation movement of a material particle and theposture varying movement of the predetermined part as a rotationalmovement of a flywheel (sixth implementation).

Similarly, in the second implementation, it is preferable that thedynamics model represents the movement of the end portion of each leg asa movement of a material particle corresponding to the leg, thehorizontal translation movement of the body as a horizontal translationmovement of a material particle corresponding to the body and theposture varying movement of the predetermined part as a rotationalmovement of a flywheel (seventh implementation).

Similarly, in the third implementation, it is preferable that thedynamics model represents the movement of the end portion of each leg asa movement of a material particle corresponding to the leg, thehorizontal translation movement of the body as a horizontal translationmovement of a material particle corresponding to the body, the verticaltranslation movement of the body as a vertical translation movement ofthe material particle corresponding to the body and the posture varyingmovement of the predetermined part as a rotational movement of aflywheel (eighth implementation).

That is, if a dynamics model represents various movements as themovements of the material particles and flywheel as in the sixth toeighth implementations, the dynamics model can adequately represents thetotal floor reaction force produced due to the combined movement of themovements of the robot as a linear coupling of the floor reaction forcesassociated with the respective movements, and the dynamics model can beused to facilitate generation of the desired gait that satisfies thedynamical equilibrium condition.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a schematic diagram showing a whole arrangement of atwo-legged mobile robot, which is a legged mobile robot according to anembodiment of the present invention;

FIG. 2 is a side view of a foot portion of each leg of the robot shownin FIG. 1;

FIG. 3 is a block diagram showing a control unit provided in the robotshown in FIG. 1;

FIG. 4 is a block diagram showing a functional arrangement of thecontrol unit shown in FIG. 3;

FIG. 5 is a diagram for illustrating a running gait for the robot shownin FIG. 1;

FIG. 6 is a graph showing an example of setting of a desired floorreaction force's vertical component;

FIG. 7 is a graph showing an example of setting of a desired ZMP;

FIGS. 8 and 9 are diagrams for illustrating movement modes (bodytranslation mode and body rotation mode, respectively) of the robot; and

FIGS. 10 and 11 are diagrams for illustrating dynamics models of therobot.

FIG. 12 is a flowchart showing main routine process performed by thegait generation device provided in the control unit shown in FIG. 3;

FIG. 13 is a diagram illustrating a divergence state of the bodyposition of the robot;

FIG. 14 is a flowchart for illustrating subroutine process in theflowchart shown in FIG. 12;

FIG. 15 is a diagram illustrating a relationship between foot landingpositions/postures in a normal gait and coordinate systems;

FIG. 16 is a graph showing an example of setting of a desired floorreaction force's vertical component for the normal gait;

FIG. 17 is a graph showing an example of setting of a floor reactionforce's horizontal component allowable range for the normal gait;

FIG. 18 is a graph showing an example of setting of a desired ZMP forthe normal gait;

FIG. 19 is a flowchart showing subroutine process in the flowchart shownin FIG. 12;

FIG. 20 is a flowchart showing subroutine process in the flowchart shownin FIG. 19;

FIG. 21 is a flowchart showing subroutine process in the flowchart shownin FIG. 20; and

FIG. 22 is a flowchart showing subroutine process in the flowchart shownin FIG. 21.

FIGS. 23 to 30 are graphs for illustrating essential process in theflowchart shown in FIG. 22;

FIG. 31 is a diagram showing an example of a trajectory of the bodyposition for the normal gait;

FIG. 32 is a flowchart showing subroutine process in the flowchart shownin FIG. 12;

FIG. 33 is a graph showing an example of setting of the floor reactionforce's horizontal component allowable range for a current time gait;

FIG. 34 is a flowchart showing subroutine process in the flowchart shownin FIG. 12;

FIG. 35 is a flowchart showing subroutine process in the flowchart shownin FIG. 34;

FIG. 36 is a flowchart showing subroutine process in the flowchart shownin FIG. 35;

FIG. 37 is a flowchart showing subroutine process in the flowchart shownin FIG. 36; and

FIG. 38 is a graph for illustrating essential process in the flowchartshown in FIG. 37.

FIG. 39 is a graph showing a relationship between body horizontalposition trajectories in the current time gait and the normal gait;

FIG. 40 is a diagram showing another example of modes of movements ofthe robot;

FIG. 41 is a graph showing a relationship between a body horizontalposition and a body horizontal velocity at an end of the current timegait converging to the normal gait;

FIG. 42 is a graph showing an example of setting of a desired floorreaction force's vertical component in the walking gait;

FIGS. 43 and 44 are flowcharts for illustrating setting process for adesired floor reaction force's vertical component in the walking gait;

FIG. 45 is a flowchart showing processing for switching of gaits betweenwalking and running;

FIGS. 46 and 47 are flowcharts for illustrating determination processingfor a desired body vertical position;

FIG. 48 is a graph showing a relationship between a body verticalposition and a floor reaction force's vertical component in the walkinggait; and

FIG. 49 is a graph showing a relationship between a body verticalposition and a floor reaction force's vertical component in the walkinggait.

BEST MODE FOR CARRYING OUT THE INVENTION

In the following, one-embodiment of a gait generation device and acontrol device for a legged mobile robot according to the presentinvention will be described with reference to the drawings. In theembodiments of the present invention, a two-legged mobile robot is takenas an example of the legged mobile robot.

FIG. 1 is a schematic diagram showing a whole arrangement of atwo-legged mobile robot, which is a legged mobile robot which uses agait generation device and a control device according to an embodimentof the present invention.

As shown in the drawing, a two-legged mobile robot (referred to as arobot, hereinafter) 1 comprises a pair of left and right legs (leglinks) 2, 2 extending downward from a body 24. The legs 2, 2 have thesame construction and each have six joints. In the order of increasingdistance from the body 24, the six joints include a hip (waist) joint10R (10L) for convolution (rotation) (rotation in the yaw direction withrespect to the body 24), a hip (waist) joint 12R (12L) for rotation inthe roll direction (about the X axis), a hip (waist) joint 14R (14L) forrotation in the pitch direction (about the Y axis), a knee joint 16R(16L) for rotation in the pitch direction, an ankle joint 18R (18L) forrotation in the pitch direction, and an ankle joint 20R (20L) forrotation in the roll direction. Reference symbols R and L indicate theright leg and the left leg, respectively.

Under the two ankle joints 18R(L) and 20R(L) of each leg 2, a foot (footportion) 22R(L) which constitutes the end portion of the leg 2 isattached. The body (base body) 24 is mounted on the top of the two legs2, 2 via the hip joints 10R, 10L, 12R, 12L, 14R and 14L (three jointsfor each leg 2). The body 24 houses a control unit 26 and the like,which will be described in detail later. In FIG. 1, for the convenienceof illustration, the control unit 26 is shown as being external to thebody 24.

In each leg 2 configured as described above, the hip joint (or waistjoint) is composed of the joints 10R(L), 12R(L) and 14R(L), and the kneejoint is composed of the joint 16R(L), and the foot joint (ankle joint)is composed of the joints 18R(L) and 20R(L). The hip joint and the kneejoint are connected to each other by a thigh link 28R(L), and the kneejoint and the foot joint are connected to each other by a crus link30R(L).

Although not shown, a pair of left and right arms are attached to theupper part of the body 24 on either side thereof, and a head is mountedon the top of the body 24. Detailed description of the arms and the headis omitted in this specification, because they have no direct concernwith the essence of the present invention. However, each arm has aplurality of joints and can make movements, such as back and forth swingwith respect to the body 24, by the action the joints.

Configuring each leg 2 as described above provides the foot 22R(L) ofthe leg 2 with six degrees of freedom with respect to the body 24. Whenthe robot 1 moves, desired movements of the feet 22R and 22L can berealized by driving the twelve joints of the two legs 2, 2 (6*2=12) toappropriate angles (in this specification, the symbol “*” representsmultiplication of scalar operation or outer product of vectoroperation). Thus, the robot 1 can move arbitrarily in athree-dimensional space.

The “position” and “velocity” of the body 24 described later in thisspecification refer to the position of a predetermined part of the body24, specifically, a predetermined representative point of the body 24(for example, a midpoint between the left and right hip joints) and themovement velocity of the point. Similarly, the “position” and “velocity”of each foot 22R(22L) refer to the position of a predeterminedrepresentative point of the foot 22R (22L) and the movement velocity ofthe point. In this embodiment, for example, the representative point ofeach foot 22R (22L) is set in the sole surface of the foot 22R (22L)(more specifically, a point at which a perpendicular line extending fromthe center of the ankle joints of each leg 2 to the sole surface of thefoot 22R (22L) intersects with the sole surface, for example).

As shown in FIG. 1, each leg 2 has a well-known six-axis force sensor 34disposed below the ankle joints 18R(L) and 20R(L) and interposed betweenthe ankle joints and the foot 22R(L). The six-axis force sensor 34detects the presence of landing of the foot 22R (22L) of the leg 2, thefloor reaction force (floor-contact load) applied to the leg 2, and thelike. The six axis force sensor outputs, to the control unit 26,detection signals of three directional components Fx, Fy and Fz of thetranslation force of the floor reaction force and three directionalcomponents Mx, My and Mz of the moment thereof. In addition, the body 24has an inclination sensor 36 for detecting the inclination (postureangle) of the body 24 with respect to the Z axis (vertical direction(direction of gravity)) and the angular velocity thereof, and theinclination sensor 36 outputs the detection signals to the control unit26. In addition, although not shown in detail, each joint in the robot 1has an electric motor 32 for driving it (see FIG. 3) and an encoder(rotary encoder) 33 (see FIG. 3) for detecting the rotation amount ofthe electric motor 32 (rotation angle of the joint). The encoder 33outputs the detection signal to the control unit 26.

As shown in FIG. 2, a spring mechanism 38 is provided above each foot22R(L) and between the foot 22R(L) and the six-axis force sensor 34, anda foot sole elastic member 40 made of a rubber or the like is attachedto the foot sole (bottom surface) of each foot 22R(L). The springmechanism 38 and the foot sole elastic member 40 constitute a compliancemechanism 42. Specifically, the spring mechanism 38 comprises arectangular guide member (not shown) mounted on the upper surface of thefoot 22R(L) and a piston member (not shown) mounted on the same side asthe ankle joint 18R(L) (the ankle joint 20R(L) is not shown in FIG. 2)and the six-axis force sensor 34 and housed in the guide member in sucha manner that the piston member can slightly move in the guide memberdue to an elastic member (such as a rubber or spring).

The foot 22R(L) shown by the solid line in FIG. 2 is in a state where nofloor reaction force is applied to the foot. When a floor reaction forceis applied to the leg 2, the spring mechanism 38 and the foot soleelastic member 40 of the compliance mechanism 42 are distorted, therebyshifting the foot 22R(L) to a position/posture as indicated by thedotted line in FIG. 2. This configuration of the compliance mechanism 42is important not only for reducing the landing impact but also forincreasing the controllability of the robot 1. Detailed description ofthe compliance mechanism is omitted herein, because it is described indetail in Japanese Patent Laid-Open No. 5-305584 previously proposed bythe applicants.

Furthermore, although not shown in FIG. 1, a joystick (manipulator) 44(see FIG. 3) for manipulating the robot 1 is provided external to therobot 1. A request concerning the gait of the robot 1, such as a requestto turn the robot 1 moving straight ahead, can be entered to the controlunit 26 as required by manipulating the joystick 44. In this case,requests that can be entered include those concerning the gait modes(walking gait, running gait or the like) of the robot 1 in motion, thelanding position/posture or landing time of a free leg, and command datafor prescribing the landing position/posture and landing time (forexample, the movement direction of the robot 1, the movement velocitythereof).

FIG. 3 is a block diagram showing an arrangement of the control unit 26.The control unit 26 is constituted by a microcomputer and comprises afirst calculation unit 60 and a second calculation unit 62 (whichconstitute a CPU), an A/D converter 50, a counter 56, a D/A converter66, a RAM 54, a ROM 64 and a bus line 52 for data transmission amongthese components. In the control unit 26, the output signals from thesix-axis force sensors 34 of the legs 2, the inclination sensor 36, thejoystick 44 and the like are converted into digital values in the A/Dconverter 50 and then input to the RAM 54 via the bus line 52. Besides,the outputs from the encoders 33 (rotary encoders) at the joints of therobot 1 are input to the RAM 54 via the counter 56.

As described later, the first calculation unit 60 generates a desiredgait, calculates a joint angle displacement command (command value ofthe displacement angle of each joint or the rotation angle of eachelectric motor 32) and transmits the command to the RAM 54. The secondcalculation unit 62 reads, from the RAM 54, the joint angle displacementcommand and the measurement value of the joint angle indicated by theoutput signal of each encoder 33, calculates the operating amount ofeach joint to be driven and outputs the operating amount data to theelectric motor 32 that drives the joint via the D/A converter 66 and aservo amplifier 32 a.

FIG. 4 is a block diagram showing a whole functional arrangement of thegait generation device and the control device of the robot 1 accordingto this embodiment. All the parts in FIG. 4 except for the partdesignated as an “actual robot” are implemented by the functionsperformed by the control unit 26 (functions performed mainly by thefirst calculation unit 60 and the second calculation unit 62). In thefollowing description, the reference symbols R and L will be omitted ifthere is no need to discriminate between the left and right legs 2.

The control unit 26 has a gait generation device 100 that generates andoutputs a desired gait flexibly and in real time as described later. Thegait generation device 100 has functions that implement means accordingto the present invention. The desired gait output from the gaitgeneration device 100 includes a desired body position/posturetrajectory (trajectories of a desired position and a desired posture ofthe body 24), a desired foot position/posture trajectory (trajectoriesof a desired position and a desired posture of each foot 22), a desiredarm posture trajectory (a trajectory of a desired posture of each arm),a desired total floor reaction force central point trajectory (a desiredZMP trajectory), and a desired total floor reaction force trajectory. Ifthe body 24 has a movable member other than the legs 2 and the arms, adesired position/posture trajectory of the movable member is added tothe desired gait.

Here, the term “trajectory” means a time-varying pattern (time-seriespattern), and is sometimes referred to also as a “pattern” in thefollowing description. In addition, the term “posture” means a spatialorientation of each component. Specifically, for example, the bodyposture is represented by the inclination angle (posture angle) of thebody 24 with respect to the Z axis (vertical axis) in the roll direction(about the X axis) and the inclination angle (posture angle) of the body24 with respect to the Z axis in the pitch direction (about the Y axis),and the foot posture is represented by the spatial azimuth angles of twoaxes set fixedly to each foot 22. In this specification, the bodyposture is sometimes referred to also as a body posture angle.

In the following description, the term “desired” will often be omittedas far as it causes no misunderstanding. The components of the gaitother than those related to the floor reaction force, that is, thecomponents related to the movement of the robot 1, such as the footposition/posture and the body position/posture, are collectivelyreferred to as a “movement” Furthermore, the floor reaction forceapplied to each foot 22 (the floor reaction force composed of thetranslation force and the moment) is referred to as an “each-foot floorreaction force”, and the resultant force of the “each-foot floorreaction forces” applied to all (two) the feet 22R and 22L of the robot1 is referred to as a “total floor reaction force”. However, in thefollowing description, there is made little mention of the each-footfloor reaction force, and therefore, the “floor reaction force” meansthe same as the “total floor reaction force” unless otherwise specified.

In general, the desired floor reaction force is represented by the pointof application, and the translation force and the moment applied to thepoint. The point of application can be set arbitrarily, so that onedesired floor reaction force can be represented in an infinite number ofways. However, if the desired floor reaction force is represented bytaking the desired floor reaction force central point (desired positionof the central point of the total floor reaction force) as the point ofapplication, the moment components of the desired floor reaction forceare 0 except for the vertical component (the moment about the verticalaxis (Z axis)). In other words, the horizontal moment components of thedesired floor reaction force about the desired floor reaction forcecentral point (the moments about the horizontal axes (X axis and Yaxis)) are 0.

Here, in a gait which satisfies the dynamical equilibrium condition, theZMP (the point where the moments applied by the resultant force of theinertial force and gravity applied to the point are 0 except for thevertical moment) calculated from the desired movement trajectory of therobot 1 agrees with the desired floor reaction force central point.Therefore, providing the desired floor reaction force central pointtrajectory means the same as providing the desired ZMP trajectory (formore information, see Japanese Patent Application No. 2000-352011 filedby the applicants).

Based on such a background, in the specification of Japanese PatentApplication No. 2000-352011 described above, the desired gait is definedas follows.

-   (a) In a broad sense, the desired gait is a set of a desired    movement trajectory and a desired floor reaction force trajectory    for a period of one or more steps.-   (b) In a narrow sense, the desired gait is a set of a desired    movement trajectory and a ZMP trajectory for a period of one step.-   (c) A gait series is a connection of several gaits.

In walking, when the vertical position of the body 24 (body height) ofthe robot 1 is determined by the body height determination methodpreviously proposed in Japanese Patent Laid-open No. 10-86080 by theapplicants, the translation floor reaction force's vertical component isdetermined accordingly. Furthermore, if the body horizontal positiontrajectory of the robot 1 is determined in such a manner that thehorizontal component of the moment produced about the desired ZMP by theresultant force of the inertial force due to the movement with thedesired gait and gravity is 0, the translation floor reaction force'shorizontal component is also determined. Therefore, in the specificationof the Japanese Patent Application No. 2000-352011, the physical valueconcerning the floor reaction force of the desired gait which has to beexplicitly set is only the desired ZMP. Therefore, as the definition ofthe desired gait in a narrow sense, the definition (b) described aboveis sufficient. On the other hand, in a running gait of the robot 1described in-this embodiment (details thereof will be described later),the floor reaction force's vertical component (the translation floorreaction force's vertical component) is also essential in controllingthe robot. Therefore, in the present invention, a desired trajectory ofthe floor reaction force's vertical component is explicitly set, andthen, trajectories of the desired body's vertical position and the likeof the robot 1 are determined. Thus, in this specification, as adefinition of the desired gait in a narrow sense, (b′) described belowis used. (b′) in a narrow sense, the desired gait is a set of a desiredmovement trajectory and a desired ZMP trajectory thereof and a desiredtranslation floor reaction force's vertical component trajectory for aperiod of one step.

In this specification, to be readily understood, the term “desired gait”is used to mean the desired gait in the narrow sense of the above (b′)unless otherwise specified. In this case, the term “one step” in thedesired gait is used to mean a leg operation starting with landing ofone leg 2 of the robot 1 and ending with landing of the other leg 2.Note that, in the following description, the “floor reaction force'svertical component” means the “translation floor reaction force'svertical component”, and the vertical component of the moment of thefloor reaction force (the component about the vertical axis) isdiscriminated from the “floor reaction force's vertical component” byusing the term “moment”. Similarly, the “floor reaction force'shorizontal component” means the “translation floor reaction force'shorizontal component”.

Furthermore, of course, a “two-leg supporting period” refers to a periodin which the two legs 2, 2 support the weight of the robot 1, a “one-legsupporting period” refers to a period in which either one of the legs 2,2 supports the weight of the robot 1, a “floating period” refers to aperiod in which both the legs 2, 2 are away from the floor (floating inthe air). The leg 2 that doesn't support the weight of the robot 1during the one-leg supporting period is referred to as a “free leg”. Inthe running gait described in this embodiment, there is no two-legsupporting period, and the one-leg supporting periods (landing periods)and the floating periods are repeated alternately. In this case, duringthe floating period, both the two legs 2, 2 don't support the weight ofthe robot 1. However, the leg 2 that has been a free leg during theone-leg supporting period immediately preceding the floating period isreferred to as a free leg during the floating period, and the leg 2 thathas been a supporting leg during the one-leg supporting periodimmediately preceding the floating period is referred to as a supportingleg during the floating period.

With the running gait shown in FIG. 5 as an example, a desired gaitgenerated by the gait generation device 100 will be describedschematically. Here, other definitions and details concerning the gaitare described in Japanese Patent Laid-Open No. 10-86081 previouslyproposed by the applicants, and therefore, the following is descriptionsthat are not made in Japanese Patent Laid-Open No. 10-86081.

First, the running gait shown in FIG. 5 will be described. This runninggait is one similar to a typical running gait of a human being. In thisrunning gait, the one-leg supporting periods in which the foot 22 ofonly one of the left and right legs 2 of the robot 1 (supporting leg)lands (is in contact with the floor) and the floating periods in whichboth the legs 2, 2 float in the air are repeated alternately. The firststate in FIG. 5 is a state (initial state) of the robot 1 at the startof a one-leg supporting period, the second state is a state thereof atthe middle of the one-leg supporting period, the third state is a statethereof at the start of a floating period following the one-legsupporting period (the end of the one-leg supporting period), the fourthstate is a state thereof at the middle of the floating period, and thefifth state is a state thereof at the end of the floating period (thestart of the next one-leg supporting period).

In this running gait, as shown in the first state in FIG. 5, the robot 1lands on the heel of the foot 22 of the supporting leg (the leading leg2 of the robot 1 in the movement direction) at the start of the one-legsupporting period. Then, as shown in the second state in FIG. 5,substantially the whole surface of the sole of the landing foot 22 (foot22 of the supporting leg) of the robot 1 comes into contact with thefloor, and then, as shown in the third state in FIG. 5, the robot 1jumps into the air by kicking the floor on the toe of the foot 22 of thesupporting leg (foot 22 of the trailing leg 2 in the movement directionof the robot 1 in the third state shown in FIG. 5). This is the timewhen the one-leg supporting period ends and the floating period starts.During the one-leg supporting period, the free leg, which is locatedrearward of the supporting leg at the start of the one-leg supportingperiod as shown in the first state in FIG. 5, is swung forward of thesupporting leg toward a next expected landing position, as shown in thesecond and third states in FIG. 5. Then, after the floating period shownas the fourth state in FIG. 5, the robot 1 lands on the heel of the foot22 of the free leg (leg 2 that has been the free leg during the one-legsupporting period immediately preceding the floating period), and then,the next one-leg supporting period starts.

With reference to the running gait in FIG. 5, a desired gait generatedby the gait generation device 100 will be described schematically. Asdescribed in detail later, when the gait generation device 100 generatesa desired gait, basic required values (required parameters) for desiredgait generation, such as landing position/posture (expected landingposition/posture) and landing time (expected landing time) of the foot22 of the free leg, are supplied to the gait generation device 100 via arequired operation of the joystick 44 or the like. The gait generationdevice 100 generates the desired gait using the required parameters.More specifically, based on the required parameters, the gait generationdevice 100 determines parameters (referred to as gait parameters) thatdefine some of the components of the desired gait, such as the desiredfoot position/posture trajectory and the desired floor reaction force'svertical component trajectory for the desired gait, and thensuccessively determines instantaneous values of the desired gait usingthe gait parameters, thereby generating a time-series pattern of thedesired gait.

In this case, the desired foot position/posture trajectory (morespecifically, desired trajectories of spatial components (such as X axiscomponent) of the position and posture of the foot) is generated foreach foot 22 using the finite duration settling filter proposed by theapplicants in Japanese Patent No. 3233450, for example. The finiteduration settling filter is a series connection of plural (three ormore, in this embodiment) stages of first-order delay filters of avariable time constant, that is, filters having a transmission functionrepresented as 1/(1+τs) where τ is a variable time constant (this filteris referred to as a unit filter, hereinafter). And, the finite durationsettling filter can generate and output a trajectory that reaches to aspecified value at a desired specified time. In this case, the timeconstant τ of the unit filter of each stage is successively set in avariable manner based on the remaining time before the specified timeafter the definite duration settling filter starts generating theoutput. More specifically, as the remaining time decreases, the value ofτ decreases from a predetermined initial value (>0), and finally, at thespecified time when the remaining time is 0, the value of τ becomes 0.And, a step input having a height depending on the specified value (morespecifically, the amount of variation of the output of the definiteduration settling filter from the initial value to the specified value)is given to the definite duration settling filter. Such a definiteduration settling filter can not only generate such an output thatreaches to the specified value at the specified time but also have thevariation rate of the output thereof being 0 or substantially 0 at thespecified time. In particular, if the unit filters are interconnected inthree or more stages (three stages are enough), the variationacceleration (the differential value of the variation rate) of theoutput of the definite duration settling filter can be 0 orsubstantially 0.

The generation of the foot position/posture trajectory (theposition/posture trajectory of the foot 22 from a landing thereof to thenext landing thereof) using such a definite duration settling filter isconducted in the following manner, for example. For example, the desiredfoot position trajectory in the X axis direction (back-and-forthdirection) is generated as follows. That is, the height of the stepinput to the definite duration settling filter is determined dependingon the X-axis directional position of the next expected landing positionof each foot 22 (more specifically, the amount of variation(displacement)in the X axis direction of the next expected landingposition with respect to the preceding landing position, this beingequivalent to the specified value) which is determined by the requiredparameters, and the time constant τ is initialized to a predeterminedinitial value. Then, the determined step input is given to the definiteduration settling filter, and generation of the trajectory of the X-axisdirectional position of the foot 22 is started. During the trajectorygeneration, the time constant τ is successively set in a variable mannerso as to decrease from the initial value to 0 by the expected landingtime of the foot 22 (which is equivalent to the specified time). In thisway, the trajectory of the position of the foot 22 in the X axisdirection that reaches to the expected landing position at the expectedlanding time is generated.

Besides, the desired foot position trajectory in the Z axis direction(vertical direction) is generated in the following manner, for example.Specifically, first, based on the next expected landing position andexpected landing time of the foot 22, the Z-axis directional position ofthe foot 22 at the time when the foot 22 reaches the maximum height(vertical position) (referred to as a highest position, hereinafter) andthe time required to reach the highest position are determined. Then,according to the highest position (which is equivalent to the specifiedvalue), the height of the step input to the definite duration settlingfilter is determined, and the time constant τ is initialized. And then,the determined step input is given to the definite duration settlingfilter, and the foot position trajectory to the highest position in theZ axis direction is successively generated. In this regard, the timeconstant τ is successively set in a variable manner so as to decreasefrom the initial value to 0 by the time when the highest position isreached (this time being equivalent to the specified time). Furthermore,when the generation of the trajectory to the highest position in the Zaxis direction is completed, the time constant τ is initialized, a stepinput of the polarity opposite to that of the step input having beenused (more specifically, a step input of the opposite polarity having aheight depending on the amount of variation in the Z axis direction fromthe highest position to the next expected landing position (this beingequivalent to the specified value)) is input to the definite durationsettling filter, and the foot position trajectory in the Z axisdirection from the highest position to the expected landing position issuccessively generated. In this regard, the time constant τ issuccessively set in a variable manner so as to decrease from the initialvalue to 0 by the expected landing time of the foot 22.

When generating the foot position trajectory in the Z axis direction,the time constant τ may be set in a variable manner so as to decreasefrom the initial value to 0 in a period from the start of the trajectorygeneration to the expected landing time of the foot 22, and the polarityof the step input may be switched to the opposite one at the time whenthe highest position is reached or the time in the vicinity thereof. Inthis case, although the foot 22 cannot reach to a desired highestposition with a high precision, the foot 22 can reach the expectedlanding position at the expected landing time without problems.

The foot posture trajectory can be generated using the definite durationsettling filter, as with the foot position trajectory described above.In this case, as for a spatial component of the foot posture whoseposture angle variation is monotonic (monotonically increasing ormonotonically decreasing), the foot posture trajectory can be generatedin the same manner as the foot position trajectory in the X axisdirection described above. Besides, as for a spatial component of thefoot posture whose posture angle variation has a maximum value orminimum value, the foot posture trajectory can be generated in the samemanner as the foot position trajectory in the Z axis direction describedabove.

Here, the desired foot position/posture trajectory generated using thedefinite duration settling filter as described above is the desiredposition/posture trajectory of each foot 22 in a supporting legcoordinate system fixed on the floor surface described later.

The desired foot position/posture trajectory generated as describedabove is configured so that the position of each foot 22 starts movingby gradually accelerating from the initial floor contact state (thestate at the start time in the desired gait) toward the expected landingposition. In addition, the desired foot position/posture trajectory isconfigured so that the variation rate of the foot position is graduallyreduced and finally reaches to 0 or substantially 0 at the expectedlanding time, and the foot reaches to the expected landing position atthe expected landing time and stops moving. Thus, at the instant wheneach foot 22 lands, the velocity thereof with respect to the floor (thevariation rate of the position of the foot 22 in the supporting legcoordinate system fixed on the floor) is 0 or substantially 0.Therefore, if the foot lands from a state where both the legs 2, 2 floatin the air (state during the floating period) in the running gait, it issubject to a reduced landing impact.

In the running gait, the vertical velocity of the body 24 is downward inthe later half of the floating period because of gravity applied to therobot 1, and the vertical velocity remains downward at the time oflanding. Therefore, if the desired foot position/posture trajectory isgenerated in such a manner that the velocity of the foot 22 with respectto the floor at the instant of landing is 0 or substantially 0, and thedesired position/posture trajectory of the body 24 is generated so as tosatisfy the dynamical equilibrium condition as described later, therelative velocity of the foot 22 of the free leg with respect to thebody 24 is upward at the time immediately before landing. That is, atthe instant of landing in the running gait, the desired gait of therobot 1 is one in which the robot 1 lands at the floor while retractingthe free leg 2 to the body 24. In other words, in the desired gait inthis embodiment, the robot 1 lands by retracting the foot 22 of the freeleg toward the body 24 so that the foot 22 has a velocity with respectto the floor of 0 or substantially 0 at the instant of landing. Thus,the landing impact is reduced and prevented from being excessive.

In this embodiment, since the definite duration settling filter is aseries connection of three or more (three, for example) stages of unitfilters, the velocity of each foot 22 (variation rate of the position ofthe foot) is reduced to 0 or substantially 0 by the expected landingtime, and the acceleration of each foot 22 is also reduced to 0 orsubstantially 0 at the expected landing time, so that the foot 22 stopsmoving. That is, the acceleration with respect to the floor is also 0 orsubstantially 0 at the instant of landing. Thus, the landing impact isfurther reduced. In particular, even if the actual landing time of therobot 1 varies from the desired landing time, the impact doesn'tincrease significantly. Incidentally, in order to simply make thevelocity of each foot 22 with respect to the floor 0 or substantially 0at the expected landing time, the definite duration settling filter maybe composed of two stages of unit filters. However, in this case, theacceleration of each foot 22 is not 0 at the expected landing timetypically.

Here, the foot posture continues to change after the foot 22 lands onthe heel at the expected landing time until substantially the wholesurface of the sole of the foot 22 comes into contact with the floor.Therefore, the foot posture trajectory is generated using the definiteduration settling filter by setting the time when substantially thewhole surface of the sole of the foot 22 comes into contact with thefloor as the specified time.

Furthermore, while the definite duration settling filter is used togenerate the foot position trajectory in this embodiment, the desiredfoot position trajectory may be generated using a function, such as apolynomial that is defined so that the variation rate of the footposition is 0 or substantially 0 (the time differential value of thefoot position is 0) at the expected landing time, and the variationacceleration of the foot position (the time differential value of thevariation rate) is 0 or substantially 0 at the expected landing time.This holds true for the generation of the desired foot posturetrajectory. However, for generation of the desired foot posturetrajectory, the function, such as a polynomial, is defined so that thevariation rate of the posture of each foot 22 and the variationacceleration thereof are 0 or substantially 0 at the time whensubstantially the whole surface of the sole of the foot 22 comes intocontact with the floor as described above.

The desired floor reaction force's vertical component trajectory is setas shown in FIG. 6, for example. In this embodiment, the shape of thedesired floor reaction force's vertical component trajectory in therunning gait (specifically, the shape thereof in the one-leg supportingperiod) is prescribed to be trapezoidal (protruding in the direction ofthe floor reaction force's vertical component increasing). The height ofthe trapezoid and the times of the apexes of the trapezoid aredetermined as gait parameters (floor reaction force's vertical componenttrajectory parameters) for defining the desired floor reaction force'svertical component trajectory. Here, during the floating period in therunning gait, the desired floor reaction force's vertical component isconstantly set to 0. As in this example, the desired floor reactionforce's vertical component trajectory is preferably set to besubstantially continuous (i.e. not to have discontinuous values). Thisis intended to make the joints of the robot 1 move smoothly whencontrolling the floor reaction force. Here, the words “substantiallycontinuous ” imply that a trajectory doesn't lose its continuity becauseof discrete values that inevitably occur when a continuous analogtrajectory (continuous trajectory in the true sense) is converted into adigital trajectory in a discrete-time system.

The desired ZMP trajectory is set as follows. In the running gait shownin FIG. 5, the robot 1 lands on the heel of the foot 22 of thesupporting leg, then jumps into the air by kicking the floor on the toeof the foot 22 of the supporting leg, and finally lands on the heel ofthe foot 22 of the free leg, as described above. Therefore, the desiredZMP trajectory during the one-leg supporting period is set so that thedesired ZMP is initially positioned at the heel of the foot 22 of thesupporting leg 2, shifted to the longitudinal middle point of the foot22 in the period in which substantially the whole surface of the sole ofthe foot 22 of the supporting leg is in contact with the floor, and thenshifted to the toe of the foot 22 of the supporting leg by the time whenthe foot takes off the floor, as shown in the upper part of FIG. 7.Here, the upper part of FIG. 7 shows the desired ZMP trajectory in the Xaxis direction (back and forth direction), and the lower part of FIG. 7shows the desired ZMP trajectory in the Y axis direction (sidewarddirection). As shown in the lower part of FIG. 7, the desired ZMPtrajectory in the Y axis direction during the one-leg supporting periodis set in such a manner that the desired ZMP is at the same position asthe central point of the ankle joints of the supporting leg 2 in the Yaxis direction.

In the running gait, after the end of the one-leg supporting period,both the legs 2, 2 move away from the floor, and the floor reactionforce's vertical component becomes 0. When the floor reaction force'svertical component is 0, that is, in the floating period, the totalcenter of gravity of the robot 1 performs a free-fall movement, and thean angular momentum variation about the total center of gravity is zero.At this point, since the moment of the resultant force of gravity andthe inertial force acting on the robot 1 is 0 at an arbitrary point onthe floor, the desired ZMP is not settled. That is, any point on thefloor satisfies the condition for ZMP that “a point of application wherethe horizontal component of the moment produced by the resultant forceof gravity and the inertial force is 0”. In other words, even if thedesired ZMP is set in an arbitrary point, the dynamical equilibriumcondition that the horizontal component of the moment applied around thedesired ZMP by the resultant force is 0. Therefore, the desired ZMP maybe set discontinuously. For example, during the floating period, thedesired ZMP may be set so as not to move from the desired ZMP positionat the time when the leg takes off the floor (when the one-legsupporting period ends) and to move discontinuously (in a step-likemanner) to the desired ZMP position at the time of landing in the end ofthe floating period. However, in this embodiment, as shown in the upperpart of FIG. 7, the X axis-directional position of the desired ZMPtrajectory during the floating period is adapted to continuously shiftfrom the toe of the foot 22 on the supporting leg side to the landingposition of the heel of the foot 22 on the free leg side by the time ofthe next landing of the free leg 2. Furthermore, as shown in the lowerpart of FIG. 7, they axis-directional position of the desired ZMPtrajectory during the floating period is adapted to continuously shiftfrom the Y axis-directional position of the center of the ankle joint ofthe supporting leg 2 to the Y axis-directional position of the center ofthe ankle joint of the free leg 2 by the time of the next landing of thefree leg 2. That is, the desired ZMP trajectory is made continuous(substantially continuous) for the whole period of the gait. Further, asdescribed later, the desired gait is generated (more specifically, thedesired body position/posture trajectory is adjusted) in such a mannerthat the moment (excluding the vertical component) of the resultantforce of gravity and the inertial force about the desired ZMP becomeszero.

A reason for making the desired ZMP trajectory continuous will bedescribed below. During the floating period, using a precise dynamicmodel, the moment about the desired ZMP applied by the resultant forceof gravity and the inertial force becomes 0, and if the desired gait isgenerated by setting the desired floor reaction force's verticalcomponent to 0, a true value of a moment applied about the origin of acoordinate system (called a global coordinate system) fixed to the floorby a resultant force of gravity and an inertial force due to thegenerated desired gait (which means a moment applied about the origin ofthe coordinate system by a resultant force of gravity and an inertialforce calculated by the precise dynamics model, and is hereinafterreferred to as a true moment about the origin) becomes 0.

However, in the case where the dynamics mode used in generating adesired gait as described above is not a precise model but anapproximate model, the true moment about the origin of the generate gaitmay not be 0. Moreover, if the approximate model is described in adifferential equation or an integral equation, which is generally usedfor representing the dynamics, the true moment about the origin dependsupon a position of the desired ZMP. Thus, the true moment about theorigin may move by a very small amount when the position of the desiredZMP is changed by a very small amount. Therefore, in this case, if theposition of the desired ZMP is moved discontinuously, the true momentabout the origin also changes discontinuously.

This means that a true inertial force of the generated gait (an inertialforce calculated by the precise model) becomes discontinuous. This alsomeans that an acceleration (angular acceleration) of displacement of anyone or all of joints of the robot 1 becomes discontinuous.

Therefore, if an approximate error of a model is taken into account, inorder to make the generated gait smooth, it is desirable to make thedesired ZMP trajectory continuous (substantially continuous) even duringthe floating period. However, in a dynamics model used in thisembodiment, which will be described later, since a desired gait, whichreduces a horizontal component of a moment about a desired ZMP to 0, canbe unconditionally generated regardless of a position of the desiredZMP, it is not always necessary to make the desired ZMP continuous.

Note that, in this embodiment, the positions and times of the apexes ofthe desired ZMP trajectory such as shown in FIG. 7 are set as ZMPtrajectory parameters (parameters defining the desired ZMP trajectory).In addition, the words “substantially continuous” used for representingthe ZMP trajectory have the same meaning as in the floor reactionforce's vertical component trajectory described above.

The ZMP trajectory parameters are determined to have a high stabilitymargin and not to change abruptly. Here, the high stability marginrefers to a state in which the desired ZMP exists near the center of asmallest projecting polygon (a so-called supporting polygon) including acontact surface of the robot 1 (for more detail, see Japanese PatentApplication Laid-Open No. 10-86081). The desired ZMP trajectory in FIG.7 is set so as to satisfy such a condition.

In addition, the desired arm posture is represented as a relativeposture with respect to the body 24.

Further, the desired body position/posture, the desired footposition/posture and a reference body posture described later aredescribed in a global coordinate system. The global coordinate system isa coordinate system that is fixed to the floor as described above. Morespecifically, a supporting leg coordinate system described later is usedas the global coordinate system.

In this embodiment, the gait generation device 100 generates not onlythe desired body posture but also a reference body posture. Thereference body posture is a body posture that is generated complyingwith a gait request (request to the gait generation device 100 fromanother device, such as a behavior planning unit, or from the outside(via the joystick 44 or the like)).

The desired body posture (hereinafter, the “body posture” without theword “reference” refers to the desired body posture) is generated so asto follow or agree with the reference body posture in the long term.

In walking, usually, the desired body posture only has to always agreewith the reference body posture as described in the embodiment describedin the specification of Japanese Patent Application No. 2000-352011filed by the applicant. In Japanese Patent Application No. 2000-352011,although the concept of the reference body posture is not described, thedesired body posture pattern is given explicitly and preferentially,which is equivalent to the desired body posture always agreeing with thereference body posture.

However, in a gait including a floating period such as running or inwalking on a low friction floor surface, the dynamical equilibriumcondition cannot be satisfied simply by adjusting the body's horizontalacceleration while causing the floor reaction force's horizontalcomponent of the desired gait to fall within the allowable range (orwithin friction limit).

Thus, in this embodiment, the desired body posture is intentionallydeviated from the reference body posture as required. More specifically,two movement modes, which are described below, are generated in acomposite manner so as to satisfy the dynamical equilibrium conditionwhile keeping the floor reaction force's horizontal component of thedesired gait within the allowable range (or within friction limit).

As shown in FIG. 8, if only the body's horizontal acceleration isbrought into perturbation (slightly changed) from a certain movementstate of the robot 1, the total center-of-gravity horizontalacceleration and the angular momentum about the total center of gravityof the robot 1 are brought into perturbation. That is, the perturbationof the body's horizontal acceleration causes perturbation of the floorreaction force's moment component about the desired ZMP (excluding thecomponent about the vertical axis) and the floor reaction force'shorizontal component without causing perturbation of the floor reactionforce's vertical component that is in balance with the resultant forceof the inertial force and gravity caused by the perturbation of thebody's horizontal acceleration in a dynamical sense (without causingperturbation of the total center-of-gravity vertical acceleration of therobot 1). The movement mode for causing perturbation of the bodyhorizontal acceleration of the robot 1 is referred to as a bodytranslation mode.

In other words, referred to as a body translation mode is such amovement that causes changes of the component of the floor reactionforce's moment about the desired ZMP (excluding the component about thevertical axis) and the floor reaction force's horizontal componentwithout causing any change of the floor reaction force's verticalcomponent.

A variation of the floor reaction force moment's component per unitacceleration at this point is denoted by ΔMp, and a variation of thefloor reaction force's horizontal component per unit acceleration isdenoted by ΔFp. If the body 24 is horizontally accelerated in theforward direction in the situation shown in FIG. 8, ΔMp and ΔFp areapplied in the directions indicated by the arrows in FIG. 8,respectively.

While, in order to be perceptually more readily understood, the bodytranslation mode is represented using the floor reaction force balancedwith the resultant force of the inertial force and gravity caused by themovement, representing the same using the resultant force of theinertial force and gravity is more accurate theoretically. Here, theresultant force and the floor reaction force have the same magnitude andthe opposite directions.

On the other hand, as shown in FIG. 9, if the body posture angularacceleration (angular acceleration of a posture angle of the body 24) isbrought into perturbation about a certain point Pr from a certainmovement state of the robot 1, the total center of gravity of the robot1 is not brought into perturbation, but the angular momentum about thetotal center of gravity is brought into perturbation. That is, theperturbation of the body posture angular acceleration about the point Prcauses perturbation of the component of the floor reaction force'smoment (excluding a component about the vertical axis) about the desiredZMP, without causing perturbations of the floor reaction force'svertical component and the floor reaction force's horizontal component.The movement mode for causing perturbation of the body posture angleacceleration of the robot 1 in this way is referred to as a bodyrotation mode.

In other words, referred to as a body rotation mode is such a movementthat causes changes of the component of the floor reaction force'smoment about the desired ZMP (excluding the component about the verticalaxis) without causing any change of the floor reaction force's verticalcomponent and the floor reaction force's horizontal component.

A variation of the floor reaction force moment's component per unitangular acceleration is denoted by ΔMr, and a variation of the floorreaction force's horizontal component per unit angular acceleration isdenoted by ΔFr. ΔFr is 0. If an angular acceleration of the body postureangle is generated to cause the body 24 to incline forward in thesituation shown in FIG. 9, ΔMr is applied in the direction indicated bythe arrow in FIG. 9.

Now, a robot dynamics model used for this embodiment will be described.In this embodiment, a simplified (approximated) dynamics model shownbelow is used. However, concerning the dynamics model described below, akinematics model (a model representing structures and dimensions ofjoints and links, that is, a model representing a relationship betweenjoint displacement and position/postures of links) is also necessary.

FIG. 10 is a robot dynamics model used for this embodiment. As shown,this dynamics model has three material particles in total, including twomaterial particles 2 m, 2 m corresponding to the legs 2, 2 of the robot1, respectively, and a material particle 24 m corresponding to the body24, and a flywheel FH having a certain inertia and no mass. Thisdynamics model is a decoupled one, that is, the dynamics of the legs 2,2 (dynamics of the material particles 2 m, 2 m) and the dynamics of thebody 24 (dynamics of the material particle 24 m and the flywheel FH)don't interfere with each other, and the dynamics of the whole robot 1is represented by a linear coupling of these dynamics. In addition, therelationship between the movement of the body 24 and the floor reactionforce is separated into the relationship between the translationmovement of the body 24 (in the body translation mode) and the floorreaction force and the relationship between the rotation movement of thebody 24 (in the body rotation mode) and the floor reaction force.Specifically, the floor reaction force caused by horizontal movement ofthe body material particle 24 m corresponds to the floor reaction forcecaused by horizontal translation movement of the body 24 (in the bodytranslation mode), and the floor reaction force caused by rotationmovement of the flywheel corresponds to the floor reaction force causedby rotation of the posture angle of the body 24 (in the body rotationmode).

Here, the mass of the arms of the robot 1 is included in the mass of thebody 24, and the body material particle 24 m has a mass including themass of the arms. In this embodiment, the movement (swing movement) ofthe arms of the robot 1 in the desired gait is attained in such a mannerthat it cancels the inertial force's moment about the vertical axisproduced in the robot 1 by the movements other than the swing movementand keeps fixed the relative position of the center of gravity of theboth arms with respect to the body 24. Thus, effects of the swingmovement of the arms on the floor reaction force moment (except for thecomponent thereof about the vertical axis) and the floor reactionforce's horizontal component are neglected.

In the following, the simplified model will be formulated. In thisregard, for the sake of simplicity of explanation, only the equation ofmotion in the sagittal plane (the plane containing the back-and-forthaxis (X axis) and the vertical axis (Z axis)) is described, and theequation of motion in the lateral plane (the plane containing thesideward axis (Y axis) and the vertical axis (Z axis)) is omitted.

For convenience of explanation, variables and parameters concerning thedynamics model are defined as follows. Each of the material particles 2m, 2 m and 24 m is a representative point of its corresponding part or apoint geometrically uniquely determined from the position/posture of thepart. For example, the position of the material particle 2 m for thesupporting leg 2 is located above the representative point of the soleof the foot 22 of the leg 2 by a predetermined distance.

-   Zsup: supporting leg material particle's vertical position-   Zswg: free leg material particle's vertical position-   Zb: body material particle's vertical position (typically different    from the body's vertical position)-   ZGtotal: total center-of-gravity vertical position-   Xsup: supporting leg material particle's horizontal position-   Xswg: free leg material particle's horizontal position-   Xb: body material particle's horizontal position (this is a point    which is shifted from the point Pr in the back-and-forth direction    by a predetermined distance. The shift is determined so that the    center of gravity in a strict model and the center of gravity in    this dynamics model agree with each other as precisely as possible    when the robot stands upright, for example. The body material    particle's horizontal position is typically different from the body    horizontal position.)-   XGtotal: total center-of-gravity horizontal position-   θ by: body posture angle about the Y axis with respect to the    vertical direction (inclination angle)-   mb: body material particle's mass-   msup: supporting leg material particle's mass-   mswg: free leg material particle's mass-   mtotal: total robot mass (=mtotal+msup+mswg)-   J: body's moment of inertia (This is an equivalent moment of inertia    in the body rotation mode.) Typically, this doesn't agree with the    moment of inertia of the body 24 of the actual robot 1.)-   Fx: floor reaction force's horizontal component (specifically, the    back-and-forth (X axis) component of the translation floor reaction    force)-   Fz: floor reaction force's vertical component (specifically, the    vertical (Z axis) component of the translation floor reaction force)    In this embodiment, this equals to the desired translation floor    reaction force's vertical component)-   My: floor reaction force moment about the desired ZMP (specifically,    the component of the floor reaction force moment about the sideward    axis (Y axis))

In this embodiment, the relationship between the position of thematerial particle 2 m of each leg 2 and the position of the foot 22 ofthe leg 2 (position of a predetermined representative point of the foot22) is previously prescribed, and thus, if the position of either one ofthem is determined, the position of the other is uniquely determined. Inaddition, the relationship between the position of the body materialparticle 24 m and the position of the body 24 (position of apredetermined representative point of the body 24) is previouslyprescribed in accordance with the posture angle of the body 24, andthus, if one of the positions and the posture angle are determined, theposition of the other is uniquely determined.

In addition, for an arbitrary variable X, dX/dt represents the firstorder differential of X, and d2X/dt represents the second orderdifferential of X. Thus, if the variable X represents a displacement,dX/dt represents the velocity, and d2X/dt represents the acceleration.The character g denotes the coefficient of the acceleration of gravity.Herein, g is a positive value.

The equations of motion for the dynamics model (formulas representingthe dynamical equilibrium condition) are represented by the formulas 01,02 and 03.

$\begin{matrix}\begin{matrix}{{Fz} = {{{mb}*\left( {g + {d\; 2{Zb}\text{/}{dt}\; 2}} \right)} +}} \\{{{msup}*\left( {g + {d\; 2{Zsup}\text{/}{dt}\; 2}} \right)} +} \\{{mswg}*\left( {g + {d\; 2{Zswg}\text{/}{dt}\; 2}} \right)}\end{matrix} & {{formula}\mspace{25mu} 01} \\\begin{matrix}{{Fx} = {{{mb}*d\; 2{Xb}\text{/}{dt}\; 2} + {{msup}*{d2Xsup}\text{/}{dt}\; 2} +}} \\{{mswg}*d\; 2{Xswg}\text{/}{dt}\; 2}\end{matrix} & {{formula}\mspace{25mu} 02} \\\begin{matrix}{{My} = {{{mb}*\left( {{Xb} - {Xzmp}} \right)*\left( {g + {d\; 2{Zb}\text{/}{dt}\; 2}} \right)} +}} \\{{{mb}*\left( {{Zb} - {Zzmp}} \right)*\left( {d\; 2{Xb}\text{/}{dt}\; 2} \right)} -} \\{{{msup}*\left( {{Xsup} - {Xzmp}} \right)*\left( {g + {d\; 2{Zsup}\text{/}{dt}\; 2}} \right)} +} \\{{{msup}*\left( {{Zsup} - {Zzmp}} \right)*\left( {d\; 2{Xsup}\text{/}{dt}\; 2} \right)} -} \\{{{mswg}*\left( {{Xswg} - {Xzmp}} \right)*\left( {g + {d\; 2{Zswg}\text{/}{dt}\; 2}} \right)} +} \\{{{mswg}*\left( {{Zswg} - {Zzmp}} \right)*\left( {d\; 2{Xswg}\text{/}{dt}\; 2} \right)} +} \\{J*d\; 2\;\theta\;{by}\text{/}{dt}\; 2}\end{matrix} & {{formula}\mspace{25mu} 03}\end{matrix}$

In addition, as for the center of gravity of the whole robot, thefollowing relational formulas hold.ZGtotal=(mb*Zb+msup*Zsup+mswg*Zswg)/mtotal   formula 04XGtotal=(mb*Xb+msup*Xsup+mswg*Xswg)/mtotal   formula 05

The following are relationships between the dynamics model and ΔFp, ΔMp,ΔFr and ΔMr.

ΔFp is a perturbation amount of Fx provided when d2Xb/dt2 is broughtinto perturbation by a unit amount in the formula 02 and, thus, can bedetermined by the following formula.ΔFp=mb   formula 06That is, the variation ΔFp of the horizontal component of the floorreaction force per unit acceleration in the body translation mode isequivalent to the mass of the body material particle 24 m in thedynamics model.

ΔMp is a perturbation amount of My provided when d2Xb/dt2 is broughtinto perturbation by a unit amount in the formula 03 and, thus, can bedetermined by the following formula.ΔMp=mb*(Zb−Zzmp)   formula 07That is, the variation ΔMp of the floor reaction force moment'scomponent per unit acceleration in the body translation mode is theproduct of the body material particle mass in the dynamics model and theheight (vertical position) of the body material particle 24 m from thedesired ZMP. The relationship between the positions of the body materialparticle 24 m and the desired ZMP and the movement of the body materialparticle 24 m is equivalent to the behavior of an inverted pendulum, thebody material particle 24 m being assumed to be the material particle ofthe inverted pendulum and the desired ZMP being assumed to be thefulcrum of the inverted pendulum.

ΔFr is a perturbation amount of Fx provided when d2θby/dt2 is broughtinto perturbation by a unit amount in the formula 02 and, thus, can bedetermined by the following formula.ΔFr=0   formula 08That is, the variation ΔFr of the translation floor reaction force'shorizontal component per unit acceleration in the body rotation mode is0.

ΔMr is a perturbation amount of My provided when d2θby/dt2 is broughtinto perturbation by a unit amount in the formula 03 and, thus, can bedetermined by the following formula.ΔMr=J   formula 09That is, the variation ΔMr of the floor reaction force moment componentper unit acceleration in the body rotation mode is equivalent to themoment of inertia of the flywheel.

The gait generation device 100 according to this embodiment generatessequentially a desired gait for one step from the landing of one leg 2of the robot 1 to the landing of the other leg 2 (the desired gait inthe narrow sense) with the desired gait for one step as a unit.Therefore, in the running gait shown in FIG. 5 generated in thisembodiment, the desired gait is generated sequentially from the start ofa one-leg supporting period to the end of the following floating period(that is, the start of the next one-leg supporting period). Here, thedesired gait to be newly generated is referred to as a “current timegait”, the next gait is referred to as a “next time gait”, and thedesired gait after next is referred to as a “next but one gait”. Inaddition, the desired gait generated immediately before the “currenttime gait” is referred to as a “last time gait”.

When the gait generation device 100 newly generates a current time gait,the required values (requests) of the expected landing position/postureand expected landing time of the foot 22 of the free leg for the nexttwo steps of the robot 1 are input to the gait generation device 100 asrequired gait parameters (or the gait generation device 100 reads therequired parameters from a storage device). Then, using the requiredparameters, the gait generation device 100 generates the correcteddesired body position/posture trajectory, the desired footposition/posture trajectory, the desired ZMP trajectory, the desiredfloor reaction force's vertical component trajectory, the desired armposture trajectory, and the like. In this case, a part of the gaitparameters defining these trajectories are corrected appropriately insuch a manner that continuity of walking is secured.

Now, taking the generation of the running gait shown in FIG. 5 as anexample, details of a gait generation process performed by the gaitgeneration device 100 will be described with reference to FIGS. 12 to38. FIG. 12 is a flowchart (structured flowchart) showing a gaitgeneration process performed by the gait generation device 100.

First, in step S010, various initialization operations, such as anoperation of initializing the time t to 0, are conducted. Thisprocessing is conducted when activating the gait generation device 100,for example. Then, the process proceeds to step S014 through step S012,where the gait generation device 100 waits for a timer interruption foreach control cycle (calculation process cycle of the flowchart in FIG.12). The control cycle is Δt.

Then, the process proceeds to step S016, where it is determined whethera gait transition is detected or not. If a gait transition is detected,the process proceeds to step S018, or otherwise, the process proceeds tostep S030. Here, the “gait transition” means a timing at whichgeneration of the last time gait is completed and generation of thecurrent time gait is started. For example, the transition from thecontrol cycle having completed generation of the last time gait to thenext control cycle is a gait transition.

When the process proceeds to step S018, the time t is initialized to 0.Then, the process proceeds to step S020, where a next time gait'ssupporting leg coordinate system, a next but one time gait's supportingleg coordinate system, a current time gait's period and a next timegait's period are read in. These supporting leg coordinate systems andgait periods are determined by the required parameters described above.That is, in this embodiment, the required parameters given to the gaitgeneration device 100 via the joystick 44 or the like include therequired values of the expected landing positions/postures of the foot22 of the free leg (position/posture of the foot 22 which is, oncelanding, rotated without slipping to come into contact with the floor atsubstantially the whole surface of the sole) and expected landing timesfor the next two steps. And, the required parameters are given to thegait generation device 100 before starting generation of the currenttime gait (before the gait transition detected in step S016) with therequired values for the first step and the required values for thesecond step being associated with the current time gait and the nexttime gait, respectively. These required values can be changed in theprocess of generating the current time gait.

The next time gait's supporting leg coordinate system is determineddepending on the required value of the expected landing position/postureof the foot 22 of the free leg for the first step (foot 22 of the freeleg in the current time gait) included in the required parameters.

For example, referring to FIG. 15, the required value of the expectedlanding position/posture of the foot 22 of the free leg in the currenttime gait (first step) (foot 22L in the drawing) is shifted in the Xaxis direction (back-and-forth direction of the foot 22R of thesupporting leg in the current gait) and the Y axis direction (sidewarddirection of the foot 22R of the supporting leg in the current gait) inthe current time gait supporting leg coordinate system by xnext andynext, respectively, and rotated by θznext about the Z axis with respectto the landing position/posture of the foot 22 of the supporting leg inthe current time gait (foot 22R in the drawing). Here, the supportingleg coordinate system is a global coordinate system (coordinate systemfixed to the floor) whose origin is set at a point where a perpendicularline, which is drawn from the center of the ankle of the supporting leg2 to the floor surface in a state where the foot 22 of the supportingleg is in a horizontal posture (more generally, parallel to the floorsurface) and substantially the whole surface of the sole of the foot 22of the supporting leg is in (intimate) contact with the floor surface,intersects with the floor surface and whose XY plane is the horizontalplane passing through the origin (in this embodiment, the point agreeswith the representative point of the foot 22 in the state wheresubstantially the whole surface of the sole of the foot 22 of thesupporting leg is in contact with the floor surface). In this case, theX axis and Y axis directions are the back-and-forth and sidewarddirections of the foot 22 of the supporting leg, respectively. Here, theorigin of the supporting leg coordinate system is not necessarilyrequired to agree with the representative point of the foot 22 (pointrepresentative of the position of the foot 22) in the state wheresubstantially the whole surface of the sole of the foot 22 of thesupporting leg is in contact with the floor surface, and may be set at apoint other than the representative point.

Here, the next time gait's supporting leg coordinate system is acoordinate system whose origin is set at the representative point (or,more specifically, a point matched to the representative point on thefloor) of the foot 22L of the free leg in the current time gait in thecase where the foot 22L lands according to the required value of theexpected landing position/posture of the foot 22L (where therepresentative point of the foot 22 agrees with the required value ofthe expected landing position and the posture (orientation) of the foot22 agrees with the required value of the expected landing posture) asshown in the drawing, and whose X′ axis and Y′ axis directions are theback-and-forth and sideward directions of the foot 22L, respectively, inthe horizontal plane passing through the origin.

Similarly, the next but one time gait's supporting leg coordinate system(see the X″Y″ coordinate in FIG. 15) is determined depending on therequired value of the expected landing position/posture of the foot 22of the free leg in the second step. The current time gait's period is atime period from the expected landing time (required value) of the foot22 of the supporting leg in the current time gait to the expectedlanding time (required value) of the foot 22 of the free leg in thefirst step (current time gait). The next time gait's period is a timeperiod from the expected landing time (required value) of the foot 22 ofthe free leg in the first step to the expected landing time (requiredvalue) of the foot 22 of the free leg in the second step.

In this embodiment, the required parameters are input to the gaitgeneration device 100 by operating the joystick 44 as required.Alternatively, the required parameters or the positions/postures andgait periods corresponding thereto may be previously stored as amovement schedule of the robot 1. Alternatively, the next time gait'ssupporting leg coordinate, the next but one time gait's supporting legcoordinate, the current time gait's period and the next time gait'speriod may be determined based on an instruction (request) input via amanipulator, such as the joystick 44, and the movement history of therobot 1 up to that moment.

Then, the process proceeds to step S022, where the gait generationdevice 100 determines gait parameters for a normal turning gait, whichis a virtual cyclic gait following the current time gait. The gaitparameters include a foot trajectory parameter for defining a desiredfoot position/posture trajectory in the normal turning gait, a referencebody posture trajectory parameter for defining a reference body posturetrajectory, and an arm trajectory parameter for defining a desired armposture trajectory, a ZMP trajectory parameter for defining a desiredZMP trajectory and a floor reaction force's vertical componenttrajectory parameter for defining a desired floor reaction force'svertical component trajectory. Furthermore, the gait parameters includea parameter for defining a desired floor reaction force's horizontalcomponent allowable range.

The term “normal turning gait” in this specification is used to refer toa cyclic gait that, when repeated, results in no discontinuity in themovement states (states of the foot position/posture, bodyposition/posture and the like) of the robot 1 at the boundaries betweenthe gaits (boundaries between the successive gaits for different steps,in this embodiment). In the following, the “normal turning gait” issometimes abbreviated as a “normal gait”.

In this embodiment, the normal turning gait is a cyclic gait comprisingtwo steps of the robot 1, and one cycle of the normal turning gaitcomprises a first turning gait following the current time gait and asecond turning gait following the first turning gait. The word “turning”is used herein because “turning” can include “straight advance” in abroad sense since a turning ratio of 0 results in straight advance.Furthermore, if the desired gait to be generated is the running gaitshown in FIG. 5, the current time gait of the desired gait is a runninggait having a one-leg supporting period and a floating period.Therefore, both of the first turning gait and second turning gait of thenormal turning gait are gaits having a one-leg supporting period and afloating period as with the current time gait. That is, the first andsecond turning gaits are basically the same as the current time gait.

More specifically, one cycle of the normal turning gait of thetwo-legged mobile robot requires at least two steps of gait in thenarrow sense described above. A complicated normal turning gait having acycle of three or more steps of gait can be set. However, as describedlater, the normal turning gait is used exclusively to determine adivergence component (described in detail later) at the end (end time)of the current time gait. Therefore, using the normal turning gaitcomprising a cycle of three or more steps is not very effective in spiteof the increasing complexity of the gait generating process. Thus, inthis embodiment, one cycle of the normal turning gait is composed of twosteps of gait (first and second turning gaits). For a legged mobilerobot having three or more legs, the number of gaits required to definethe normal turning gait increases accordingly. In the following, for theconvenience of explanation, the normal turning gait comprising aplurality of gaits in the narrow sense (two steps of gait in thisembodiment) is regarded as one step of gait.

The normal turning gait is a provisional gait created in the gaitgeneration device 100 for determining movement states of the robot 1including the divergence component at the end of the current time gait,the body's vertical positional velocity, the body's posture angle andthe angular velocity, and is not output directly from the gaitgeneration device 100.

Here, the word “divergence” means that the position of the body 24 ofthe two-legged mobile robot 1 is displaced far from the positions of thefeet 22, 22, as shown in FIG. 13. The value of the divergence componentis a numerical value that represents the degree of displacement of theposition of the body 24 of the two-legged mobile robot 1 from thepositions of the feet 22, 22 (more specifically, the origin of theglobal coordinate system (supporting leg coordinate system) set on thesurface with which the foot 22 of the supporting leg is in contact).

In this embodiment, the desired gait is generated by using thedivergence component as a reference index in order to allow the gait tobe continuous without a divergence occurring in the gait. However, evenan initial divergence component of a normal gait (a divergence componentof a normal gait at the initial time thereof), which is a representativeexample of continuous gaits, is not always simply 0 and varies with aparameter of the normal gait (the normal gait is a cyclic gait that hasno discontinuity in the trajectory and can be repeated with the samepattern or, in theory, can be infinitely repeated without divergenceeven if repeated infinitely in theory). That is, the appropriatedivergence component varies with the gait configuration, for example,the manner of walking or running. Thus, in this embodiment, the currenttime gait is generated in such a manner that the normal gait to begenerated following the current time gait is set in accordance with therequired parameters of the current time gait, the initial divergencecomponent of the normal gait is determined, and then the finaldivergence component of the current gait is made to agree with theinitial divergence component of the normal gait (more generally, thecurrent gait is made to be continuous with or close to the normal gait).The basic principle of such gait generation is the same as thatdescribed in Japanese Patent Application No. 2000-352011 previouslyproposed by the applicants.

In the embodiments of the present invention, the linearthree-material-particle dynamics model used in the first embodimentdescribe in Japanese Patent Application No. 2000-352011 is not used.However, the concept of the divergence component and convergencecomponent defined by the following formulas can be applied, in anapproximation manner with an adequate precision, to a perturbation ofthe behavior of the nonlinear dynamics model, such as the model shown inFIG. 10.divergence component=body material particle's horizontal position+bodymaterial particle's horizontal velocity/ω0   formula 10convergence component=body material particle's horizontal position−bodymaterial particle's horizontal velocity/ω0   formula 11

However, the body material particle's horizontal position is the bodymaterial particle's horizontal position Xb in the dynamics model shownin FIG. 10.

Furthermore, ω0 is a predetermined value, and the value during runninghas to be slightly varied from the value during walking gait generationdescribed in Japanese Patent Application No. 2000-352011.

Other details concerning the divergence and convergence components aredescribed in Japanese Patent Application No. 2000-352011, and thus,further description thereof is omitted herein.

In this embodiment, in addition to the method described in Japanesepatent application no. 2000-352011, as described later, a gait parameterthat defines the desired floor reaction force's vertical componenttrajectory is set, and the total center-of-gravity vertical position ofthe robot 1 is determined so as to satisfy, in terms of dynamics, thedesired floor reaction force's vertical component. In this case, thesecond-order integral of the floor reaction force's vertical componentdefines the total center-of-gravity vertical position of the robot 1.Therefore, if the desired floor reaction force's vertical component isset inadequately, the total center-of-gravity vertical position orbody's vertical position of the robot 1 becomes too high or too low.Therefore, how to set the desired floor reaction force's verticalcomponent is also an important problem. However, a relationship betweena floor reaction force's vertical component and a body vertical positionis similar to a relationship between a ZMP and a body horizontalposition. Thus, only by slightly changing a part of desired ZMPdetermination method for making a body horizontal position/velocityappropriate as indicated in this embodiment described below, the desiredZMP determination method can be applied to a determination method for adesired floor reaction force's vertical component for making a bodyvertical position/velocity appropriate.

Returning to the main subject, in step S022, a process described belowis conducted in accordance with the flowchart shown in FIG. 14.

First, in step S100, foot trajectory parameters of the gait parametersfor the normal gait are determined in such a manner that the footposition/posture trajectories of the current time gait, the firstturning gait and the second turning gait are connected to each other inthis order. A specific setting manner will be described below withreference to FIG. 15. In the following description, the foot 22 of thesupporting leg 2 is referred to as a supporting leg's foot, and the foot22 of the free leg 2 is referred to as a free leg's foot. Furthermore,the terms “initial (start)” and “final (end)” concerning the “gait” meanthe start time and end time of the gait, respectively, or instantaneousgaits at the start time and end time of the gait, respectively.

The foot trajectory parameters include supporting leg's footpositions/postures and free leg's foot positions/postures at the startand end of the first turning gait and the second turning gait, and gaitperiods of the turning gaits. Of the foot trajectory parameters, thefree leg's foot position/posture at the start of the first turning gaitis regarded as the supporting leg's foot position/posture at the end ofthe current time gait seen from the next time's gait supporting legcoordinate system. In this case, in the running gait, the supportingleg's foot 22 at the end of the current time gait has floated in theair. The supporting leg's foot position/posture at the end of thecurrent time is determined by using the finite duration settling filterto generate, until the end of the current gait, the footposition/posture trajectory (specifically, trajectory seen from the nexttime gait's supporting leg coordinate system) that leads from thesupporting leg's foot position/posture at the start of the current timegait (=the free leg's foot position/posture at the end of the last timegait) to the free leg's foot position/posture at the end of the nexttime gait that is determined depending on the required value of theexpected landing position/posture of the free leg's foot 22 for thesecond step (required value of the expected landing position/posture inthe next time gait of the supporting leg's foot 22 in the current timegait) of the required parameters or the next but one time gait'ssupporting leg coordinate system associated with the required value.

Here, the free leg's foot position/posture at the end of the next timegait is determined in such a manner that the position/posture of thefoot 22 rotated from the position/posture by a predetermined angle tothe horizontal posture in the pitch direction by lowering the toe whilekeeping the foot 22 in contact with the floor agrees with theposition/posture thereof in the next but one time gait's supporting legcoordinate system. In other words, the free leg's foot position/postureat the end of the next time gait is the position/posture of the foot 22that is rotated by a predetermined angle in the pitch direction byraising the toe while keeping the foot 22 in contact with the floorwithout slipping (a state where the foot 22 has the toe raised and theheel in contact with the floor) from the required value of the landingposition/posture of the free leg's foot 22 in the second step of therequired parameters.

In addition, the supporting leg's foot position/posture at the start ofthe first turning gait is regarded as the free leg's footposition/posture at the end of the current time gait seen from the nexttime gait's supporting leg coordinate system. In this case, as withthe-free leg's foot position/posture at the end of the next time gait,the free leg's foot position/posture at the end of the current time gaitis determined depending on the next time gait's supporting legcoordinate system or the required value of the expected landingposition/posture of the free leg for the first step (current time gait)of the required parameters associated with the next time gait'ssupporting leg coordinate system. That is, the free leg's footposition/posture at the end of the current time gait is determined insuch a manner that the representative point of the foot 22 rotated fromthe position/posture by lowering the toe while keeping the foot 22 incontact with the floor to bring substantially the whole of the sole ofthe foot 22 into contact with the floor agrees with the origin of thenext gait's supporting leg coordinate system.

As with the free leg's foot position/posture at the end of the currenttime gait and the free leg's foot position/posture at the end of thenext time gait, the free leg's position/posture at the end of the firstturning gait is determined based on the position/posture in the next butone time gait's supporting leg coordinate system seen from the next timegait's supporting leg coordinate system. More specifically, the freeleg's foot position/posture at the end of the first turning gait is setin such a manner that the position/posture of the foot 22 that isrotated from the position/posture by a predetermined angle to thehorizontal posture while keeping the foot 22 in contact with the floorwithout slipping agrees with the position/posture in the next but onetime gait's supporting leg coordinate system seen from the next timegait's supporting leg coordinate system.

At the end of the first turning gait, the supporting leg's foot 22 isaway from the floor and floats in the air. To determine the trajectoryafter the supporting leg's foot 22 takes off the floor, an expectedlanding position/posture of the first turning gait's supporting leg'sfoot is set. The expected landing position/posture of the first turninggait's supporting leg's foot is set based on the position/posture in anext but two gait's supporting leg coordinate system seen from the nexttime gait's supporting leg coordinate system. More specifically, theexpected landing position/posture of the first turning gait's supportingleg's foot is the position/posture in the next but two gait's supportingleg coordinate system seen from the next time gait's supporting legcoordinate system. Here, the next but two gait's supporting legcoordinate system is set in such a manner that the relativeposition/posture relationship between the next but one time gait'ssupporting leg coordinate system and the next but two gait's supportingleg coordinate system agrees with the relative position/posturerelationship between the current time gait's supporting leg coordinatesystem and the next time gait's supporting leg coordinate system.

As with the supporting leg's foot position/posture at the start of thefirst turning gait, the supporting leg's foot position/posture at theend of the first turning gait is determined by using the finite durationsettling filter to generate the foot position/posture trajectory leadingfrom the supporting leg's foot position/posture at the start of thefirst turning gait to the expected landing position/posture of the firstturning gait's supporting leg's foot (more specifically, trajectory seenfrom the next time gait's supporting leg coordinate system) until theend of the first turning gait.

The free leg's foot position/posture at the start of the second turninggait is the supporting leg's foot position/posture at the end of thefirst turning gait seen from the next but one time gait's supporting legcoordinate system. The supporting leg's foot position/posture at thestart of the second turning gait is the free leg's foot position/postureat the end of the first turning gait seen from the next but one timegait's supporting leg coordinate system.

The free leg's foot position/posture at the end of the second turninggait is the free leg's foot position/posture at the end of the currenttime gait seen from the current time gait's supporting leg coordinatesystem. The supporting leg's foot position/posture at the end of thesecond turning gait is the supporting leg's foot position/posture at theend of the current time gait seen from the current time gait'ssupporting leg coordinate system.

The gait periods of the first and second turning gaits are set to be thesame as the period of the next time gait. The gait periods of the firstand second turning gaits are not necessarily required to be the same.However, both the periods are preferably determined in accordance withthe period of the next time gait. Movement parameters of the currenttime gait, the first turning gait and the second turning gait other thanthose described above (including time parameters including the two legsupporting period duration) are appropriately determined so as tosatisfy the gait requirements (for example, that the velocity of anactuator falls within an allowable range, that an allowable angle of theactuator is not surpassed and that a foot is not in contact with thefloor or the like) in accordance with the parameters determined asdescribed above.

Then, the process proceeds to step S102, where the reference bodyposition/posture trajectory parameter for defining the reference bodyposition/posture trajectory to be followed by the desired body postureis determined. The reference body posture is not necessarily required tobe constant, as far as the reference body posture is the same at thestart of the normal gait (start of the first turning gait) and the endthereof (end of the second turning gait) (the posture angle of thereference body posture and the angular velocity thereof are the same atthe start and the end of the normal gait). However, in this embodiment,to be readily understood, the reference body posture is the uprightposture (vertical posture). That is, in this embodiment, the referencebody posture is the upright posture throughout the duration of thenormal gait. Therefore, in this embodiment, the angular velocity andangular acceleration of the posture angle of the reference body postureare 0.

Then, the process proceeds to step S104, where arm posture trajectoryparameters, more specifically, the arm posture trajectory parametersother than those concerning the angular momentums of the arms about thevertical axis (or body trunk axis) are determined. For example, armposture trajectory parameters, such as the relative height of the tip ofthe arm with respect to the body 24 or the relative position of thecenter of gravity of the entire arm with respect to the body 24, aredetermined. In this embodiment, the relative position of the center ofgravity of the entire arm is kept constant with respect to the body.

Then, the process proceeds to step S106, where floor reaction force'svertical component trajectory parameters are set. In this case, thefloor reaction force's vertical component trajectory parameters are setin such a manner that the floor reaction force's vertical componenttrajectory defined by the parameters is substantially continuous (i.e.,has no step-wise discrete values) in the first and second turning gaitsas shown in FIG. 6. That is, the desired floor reaction force's verticalcomponent trajectory of the normal turning gait is set to be the patternshown in FIG. 16. According to this pattern, both for the first andsecond turning gaits, the floor reaction force's vertical componentvaries in a trapezoidal shape during the one leg supporting period andis kept at 0 during the floating period. And, the times of the apexes ofthe pattern and the heights (peak values) of the trapezoids are set asthe floor reaction force's vertical component trajectory parameters.

In setting the floor reaction force's vertical component trajectoryparameters, the average value of the floor reaction force's verticalcomponent for the whole gait duration (period of one cycle of the normalgait, which is a sum of the periods of the first and second turninggaits) is made to agree with the weight of the robot 1. That is, theaverage value of the floor reaction force's vertical component is madeequal in magnitude and opposite in direction to gravity applied to therobot 1.

Setting the floor reaction force's vertical component trajectory asdescribed above is required to satisfy the normal gait requirement. Thenormal gait requirement is that the initial states of all the statevariables (positions, postures and velocities of the parts of the robot1) of the gait seen from the supporting leg coordinate system(coordinate system set on the surface at which the supporting leg's foot22 is in contact) agree with the final states of the gait (final statesof the second turning gait) seen from the next supporting leg coordinatesystem (supporting leg coordinate system of the next first turning gait)(hereinafter, this requirement is sometimes referred to as a boundaryrequirement of the normal gait). Therefore, the difference between thetotal center-of-gravity vertical velocity of the robot 1 at the end ofthe normal gait and the total center-of-gravity vertical velocity at thestart of the normal gait (more specifically, difference between thetotal center-of-gravity vertical velocity at the end of the secondturning gait and the total center-of-gravity vertical velocity at thestart of the first turning gait) has to be 0. Since the differencedescribed above is an integral (first order integral) of the differencebetween the floor reaction force's vertical component and gravity, thefloor reaction force's vertical component trajectory has to be set asdescribed above in order for the difference to be 0.

In this embodiment, the average values of the floor reaction force'svertical component for the periods of the first and second turning gaitsare made to agree with the weight of the robot 1. More specifically, forexample, after the times of the apexes of the trapezoidal line of thefloor reaction force's vertical component trajectory in the first andsecond turning gaits are determined in accordance with the periods ofthe gaits, the heights of the trapezoids are determined in such a mannerthat the average values of the floor reaction force's vertical componentfor the first and second turning gaits agree with the weight of therobot 1 (the height of the trapezoids is determined by solving anequation representing agreement between the average values and theweight with the height of the trapezoid being assumed to be an unknownquantity).

This results in a difference of 0 between the total center-of-gravityvertical velocity at the end of the first turning gait and the totalcenter-of-gravity vertical velocity at the start of the first turninggait and a difference of 0 between the total center-of-gravity verticalcomponent at the end of the second turning gait and the totalcenter-of-gravity vertical velocity at the start of the second turninggait. However, this is not essential. Alternatively, for example, thebody's vertical position becomes too high or too low and, thus, therobot takes an unreasonable posture in the vicinity of the boundarybetween the first and second turning gaits, the height of the trapezoidof the floor reaction force's vertical component trajectory for theturning gaits may be modified from the state where the average valuesfor the turning gaits agree with the weight.

Then, the process proceeds to step S108, where an allowable range[Fxmin, Fxmax] (more specifically, a parameter that defines theallowable range) of the floor reaction force's horizontal component isdetermined, as shown in FIG. 17, in accordance with the floor reactionforce's vertical component trajectory determined as described above asshown in FIG. 16. The polygonal line on the negative side in FIG. 17represents the floor reaction force's horizontal component's allowablelower limit value Fxmin, and the polygonal line on the positive siderepresents the floor reaction force's horizontal component's allowableupper limit value Fxmax. The following is a supplementary description ofa method of setting these values. In the following, a case where thefloor surface is horizontal will be described.

The floor reaction force's horizontal component occurs due to frictionbetween the floor and the foot 22. However, friction cannot be producedinfinitely. Therefore, in order to prevent the actual robot 1 fromslipping when it moves in accordance with the desired gait generated,the floor reaction force's horizontal component of the desired gait hasto always fall within the friction limit. Thus, in order to satisfy thisrequirement, the floor reaction force's horizontal component allowablerange is set, and, as described later, the desired gait is generated insuch a manner that the floor reaction force's horizontal component ofthe desired gait falls within the allowable range.

Assuming that the friction coefficient between the floor and the foot 22is μ, the value of Fxmin has to be always equal to or higher than−μ*(floor reaction force's vertical component), and the value of Fxmaxhas to be always equal to or lower than μ*(floor reaction force'svertical component). The simplest settings are as follows. Herein, ka isa positive constant smaller than 1.Fxmin=−ka*μ*(floor reaction force's vertical component)Fxmax=ka*μ*(floor reaction force's vertical component)  formula 12

The floor reaction force's horizontal component allowable range shown inFIG. 17 is an exemplary range set in accordance with the formula 12. Asparameters for defining the floor reaction force's horizontal componentallowable range, the times of the apexes of trapezoidal waveform and thevalues of the waveform at the times in FIG. 17 may be set. However, inthe case where the floor reaction force's horizontal component allowablerange is determined by the formula 12, the parameter to be set may beonly the value of (ka*μ) in the formula 12.

As far as the requirement (that the floor reaction force's horizontalcomponent of the desired gait always falls within the friction limit) issatisfied, the floor reaction force's horizontal component allowablerange may be set in any other setting method.

Then, the process proceeds to step S110, where a ZMP trajectoryparameter that define the ZMP trajectory for the normal gait, which is asum of the first and second turning gaits, is determined. In this case,the desired ZMP trajectory is determined to have a high stability marginand not to change abruptly, as described above.

More specifically, in the running gait shown in FIG. 5, the heel of thesupporting leg's foot 22 first lands, and some time after that,substantially the whole surface of the sole of the supporting leg's foot22 comes into contact with the floor. Then, only the toe of thesupporting leg's foot 22 comes into contact with the floor. Then, therobot jumps into the air by kicking the floor on the toe of thesupporting leg's foot 22, and finally, the heel of the free leg's foot22 lands. Besides, the desired ZMP has to lie within the contactsurface. Thus, in this embodiment, as shown in the upper part of FIG. 7,both for the first and second turning gaits of the normal gait, thex-axis directional position of the desired ZMP is set to remain at theinitial position, which is the position of the heel of the supportingleg's foot 22, until substantially the whole surface of the sole of thefoot 22 comes into contact with the floor. Then, the desired ZMP isshifted to the middle of the supporting leg's foot 22 and then to thetoe, making the foot 22 in contact with the floor only at the toe. Then,the desired ZMP remains at the position of the toe of the supportingleg's foot 22 until the foot takes off the floor. After that, asdescribed above, the desired ZMP is shifted continuously from the toe ofthe supporting leg's foot 22 to the landing position of the heel of thefree leg's foot 22 by the time of the next landing of the free leg'sfoot 22. Thus, the desired ZMP trajectory (X-axis directionaltrajectory) for the normal gait comprising the first and second turninggaits is as shown in FIG. 18. The times and positions of the apexes ofthe desired ZMP trajectory are set as ZMP trajectory parameters. In thiscase, the times of the apexes of the trajectory are determined based onthe gait periods of the first and second turning gaits determined basedon the required parameters, and the positions of the apexes of thetrajectory are determined based on the positions/postures in the nexttime gait's supporting leg coordinate system and the next but one timegait's supporting leg coordinate system, or based on the required valuesof the expected landing positions/postures of the free leg's foot forthe first and second steps of the required parameters that define thesecoordinate systems. The Y-axis directional position of the ZMPtrajectory is determined as shown in the lower part of FIG. 7. Morespecifically, the trajectory of the Y-axis directional position of thedesired ZMP for the first turning gait is set in the same pattern asthat shown in the lower part of FIG. 7, and the trajectory of the Y-axisdirectional position of the desired ZMP for the second turning gait isset to have the same shape as that for the first turning gait and to beconnected to the end of the trajectory for the first turning gait.

Finally, the process proceeds to step S112, where the initial time, theend time and the period of one step (one cycle) of the normal gait areredefined as follows.

The normal gait has to be a gait having state variables that arecontinuous at the start and the end thereof. For convenience ofdetermination of such a gait, in this embodiment, until the normal gaitis determined, unlike the definition of the gait in the narrow sense,the initial time, the end time and the period of one step of the normalgait are defined as shown in FIG. 16. That is, the time at which thefloor reaction force's vertical component is decreased to some degree inthe latter half of the one leg supporting period of the first turninggait is set as the initial time Ts of the normal gait. As shown in FIG.7, the initial time Ts is preferably set to the instant when thesupporting leg's foot 22 having been in contact with the floor atsubstantially the whole surface of the sole thereof comes into contactwith the floor only at the toe thereof or a time immediately before theinstant (the end time of the period in which whole the sole of the footis in contact with the floor or a time immediately before the end timein FIG. 7). In addition, as for the relationship between the desired ZMPand the time Ts determined in step S110 and shown in FIG. 18 (or FIG.7), it is preferable that the time Ts is the instant when the supportingleg's foot is in contact with the floor only at the toe after thedesired ZMP has been completely shifted to the toe of the supportingleg's foot 22 through the middle thereof after substantially the wholesurface of the sole of the supporting leg's foot 22 had come intocontact with the floor in the first turning gait. Such an initial timeTs is determined in accordance with the desired ZMP trajectory parameterpreviously determined, for example. The reason why the initial time Tsis determined as described above will be described later.

Furthermore, as shown in FIG. 16, the period Tcyc of the normal gait isa sum of the gait periods of the first and second turning gaits. The endtime of the normal gait is Te. Te is the time Ts plus Tcyc.

From the point in time when the normal gait is determined (when the loopof step S204 in FIG. 19 described later exits), the definitions of theinitial time, the end time and the like of the gait in the narrow sensedescribed above are adopted again. In the following description, theinitial time according to the definition of the gait in the narrow sensedescribed above (the time of the landing of the supporting leg's foot22) is assumed to be 0, and reference symbol Ts is used to discriminatethis original initial time 0 from the above-described initial time Tsused until the normal gait is determined (sometimes simply abbreviatedas “Ts”).

After the processings from steps S010 to S022 in FIG. 12 is conducted,the process proceeds to step S204, where initial states of the normalgait are calculated. The initial states calculated in this step includethe initial body horizontal position/velocity (initial body position andinitial body velocity in the horizontal direction), the initial bodyvertical position/velocity (initial body vertical position and initialbody velocity in the vertical direction), the initial divergencecomponent, the initial body posture angle and the angular velocitythereof for the normal gait. These initial states are calculated in asearching manner according to the flowchart in FIG. 19.

In the flowchart in FIG. 19, first, in step S200, the initial states(states at the initial time Ts) of the desired foot position/posture,the desired arm posture and the desired body posture angle (postureangle and direction) are determined based on the gait parameters for thenormal gait (parameters determined in step S022 in FIG. 12). The term“state” refers to a position, a posture angle and variation rates (timedifferentials) thereof.

In this case, the initial state of the desired foot position/posture ofthe supporting leg is determined by using the finite duration settlingfilter to generate the foot position/posture trajectory (trajectory seenfrom the next time gait's supporting leg coordinate system) leading fromthe supporting leg's foot position/posture at the start of the firstturning gait of the foot trajectory parameters determined in step S100in FIG. 14 to the free leg's foot position/posture at the end of thesecond turning gait until the time Ts. The initial state of the desiredfoot position/posture for the free leg is determined by using the finiteduration settling filter to generate the foot position/posturetrajectory leading from the supporting leg's foot position/posture atthe start of the current time gait seen from the next time gait'ssupporting leg coordinate system to the free leg's foot position/postureat the end of the first turning gait until the time Ts. Besides, theinitial state of the desired arm posture is determined by determiningthe arm posture (total center-of-gravity position of the arms withrespect to the body 24, for example) at the time Ts based on the armposture trajectory parameters determined in step S104 in FIG. 14.Besides, as the initial state of the desired body posture angle, thereference body posture (posture angle) and the angular velocity thereofat the time Ts, which are determined based on the reference body posturetrajectory parameters determined in step S102 in FIG. 14, aredetermined. In this embodiment, since the reference state posture angleis the vertical posture, the initial state of the desired body postureangle is 0 (the posture angle and the angular velocity thereof are 0).Furthermore, in this embodiment, the desired foot position/posturetrajectory, the floor reaction force's vertical component trajectory andthe desired ZMP trajectory for the normal gait are independentlydetermined from the foot trajectory parameters, the floor reactionforce's vertical component trajectory parameters and the ZMP trajectoryparameters determined in the flowchart in FIG. 14, respectively. Forexample, the instantaneous desired foot position/posture for the normalgait is determined based on the foot trajectory parameters,independently of the instantaneous value of the floor reaction force'svertical component.

Then, in step S202, (Xs, Vxs), which are candidates for the initial bodyhorizontal position/velocity (that is, body horizontal position/posturecandidates at the initial time Ts), are provisionally determined, whereXs is the horizontal position and Vxs is the horizontal velocity. Thecandidates (Xs, Vxs) provisionally determined in this step may bearbitrary ones and, for example, may be the body horizontalposition/velocity of the initial states of the normal gait determinedwhen the last time gait is generated.

For the simplicity of explanation, a case where the initial states forthe normal gait in the X direction (back and forth direction) in thesagittal plane are searched for is taken as an example. Actually,however, both for the position and velocity, the initial states for thenormal gait (initial states that satisfy the boundary requirement of thenormal gait) for the X direction (back and forth direction) and the Ydirection (sideward direction) have to be searched for separately orconcurrently.

As the determination method in a searching manner, the simplex method ora method of determining an affine Jacobian (sensitivity matrix) anddetermining a next candidate by the steepest descent method may be used.In this embodiment, the steepest descent method is used.

Then, in step S206 after step S204, the initial (time Ts) body verticalposition/velocity (Zs, Vzs) is determined, where Zs is the verticalposition and Vzs is the vertical velocity.

In this embodiment, the initial body vertical velocity Vzs is determinedas follows in an analytical manner.

For the robot 1, the following dynamical relationship holds.

$\begin{matrix}{{{\left( {{final}\mspace{14mu}{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}}\; \right) - \left( {{initial}\mspace{14mu}{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}} \right)} = {{{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}\left( {{floor}\mspace{14mu}{reaction}\mspace{14mu}{{force}'}s\mspace{14mu}{vertical}\mspace{14mu}{component}\text{/}{total}\mspace{14mu}{mass}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{robot}} \right)} + {{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{gravitational}\mspace{14mu}{acceleration}}\; + {\left( {{initial}\mspace{14mu}{total}\mspace{14mu}{center}\;\text{-}{of}\text{-}\;{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}} \right)*\left( {{duration}\mspace{14mu}{of}\mspace{14mu}{one}\mspace{14mu}{step}} \right)}}}\;} & {{formula}\mspace{20mu} 13}\end{matrix}$(The gravitational acceleration is a negative value.)

In the normal gait, since the final total center-of-gravity verticalposition agrees with the initial total center-of-gravity verticalposition, the right side in the formula 13 has to be 0. Thus, theinitial total center-of-gravity vertical velocity can be determined fromthese relationships. Specifically, a value obtained by dividing thefloor reaction force's vertical component, which is calculated from thefloor reaction force's vertical component parameters set in step S104 inFIG. 14, by the total mass of the robot 1 is integrated two times withrespect to the period of one step (from the time Ts to the time Te),thereby determining the displacement of the total center of gravity dueto the floor reaction force's vertical component (first term in theright side of the formula 13). Furthermore, the gravitationalacceleration is integrated two times with respect to the period of onestep, thereby determining the displacement of the total center ofgravity due to gravity (second term in the right side of the formula13). Then, the sum of the displacement of the total center of gravitydue to the floor reaction force and the displacement of the total centerof gravity due to gravity is inverted in sign, and the resulting valueis divided by the duration of one step (duration of one cycle Tcycl ofthe normal gait), thereby determining the initial totalcenter-of-gravity vertical velocity.

Then, in order to determine the initial body vertical position Zs, thetotal center-of-gravity vertical velocity at the time 0 is determinedusing the following formula. In this process, the value determined fromthe formula 13 as described above is substituted for the totalcenter-of-gravity vertical velocity at the time Ts in the followingformula, and the integral time is from the time 0 to the time Ts.

$\begin{matrix}{{\left( {{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu}{Ts}} \right) - \left( {{total}\mspace{14mu}{center}\;\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu} 0} \right)} = {{{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{11mu}\left( {{floor}\mspace{14mu}{reaction}\mspace{14mu}{{force}'}s\mspace{14mu}{vertical}\mspace{14mu}{component}\text{/}{total}\mspace{14mu}{mass}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{robot}} \right)} + {{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{gravitational}\mspace{14mu}{acceleration}}}} & {{formula}\mspace{20mu} 14}\end{matrix}$(The gravitational acceleration is a negative value.)

Then, the body height determination method proposed in Japanese PatentLaid-Open No. 10-86080 by the applicants is used to determine the bodyheight (body vertical position) at the time 0 (that is, at the instantof landing). In this process, the body vertical position (body height)that allows the knees of the legs 2, 2 not to be fully stretched at thetime 0 is determined based on the foot position/posture at the time 0(the supporting leg's foot position/posture at the start of the firstturning gait (at the time 0) and the free leg's foot position/posture atthe start of the first turning gait (at the time 0) determined in stepS100 in FIG. 14) and a predetermined geometrical condition concerningthe bending angle of the knees of the legs 2. Specifically, assumingthat the bending angle of the knee of the supporting leg 2 is θsup andthe bending angle the knee of the free leg 2 is θswg, the body verticalposition is determined in such a manner that the sum of the inversenumbers of the sinusoidal values of the knee bending angles θsup andθswg equals to a predetermined value (finite value), for example. Here,the knee bending angles θsup and θswg are the angles of the center axisof the crus part with respect to the center axis of the thigh part ofeach leg 2 and increase from 0 as the knee is bent from a state whereeach leg 2 is fully stretched. Such a method of determining the verticalposition of the body 24 is described in detail in Japanese PatentLaid-Open No. 10-86080, and thus, further description thereof is omittedherein.

Then, from the body vertical position and the foot position/posture atthe time 0 thus determined, the total center-of-gravity verticalposition at the time 0 is determined using the robot 1 model. Forexample, the kinematics model represented by the formula 04, whichcorresponds to the model shown in FIG. 10, may be used to determine thetotal center-of-gravity vertical position at the time 0. Specifically,the vertical position of the body material particle 24 m is determinedfrom the body vertical position and the body posture angle (0 in thisembodiment) at the time 0, and the vertical positions of the supportingleg material particle 2 m and the free leg material particle 2 m aredetermined from the supporting leg's foot position/posture and the freeleg's foot position/posture at the time 0 (the supporting leg's footposition/posture at the start of the first turning gait and the freeleg's foot position/posture at the start of the first turning gaitdetermined in step S100 in FIG. 14), respectively. Then, these verticalpositions of the body material particle 24 m, the supporting legmaterial particle 2 m and the free leg material particle 2 m aresubstituted for Zb, Zsup and Zswg in the formula 04, respectively,thereby determining the total center-of-gravity vertical position(ZGtotal in the formula 04). Alternatively, a more precise model of therobot 1 (for example, the multi-mass model such as shown in FIG. 11) maybe used to take into consideration the body horizontal position and thearm posture at the time 0 to determine the total center-of-gravityvertical position at the time 0.

Then, in the formula 13, the total center-of-gravity vertical positionat the time 0 determined as described above is substituted for theinitial total center-of-gravity vertical position in the left side ofthe formula 13, the total center-of-gravity vertical velocity at thetime 0 determined as described above is substituted for the initialtotal center-of-gravity vertical velocity in the right side of theformula 13, Ts is substituted for the duration of one step in theformula 13, and a period from the time 0 to the time Ts is defined asthe integral period, thereby calculating the value of the final totalcenter-of-gravity vertical position in the left side of the formula 13,which is regarded as the initial (time Ts) total center-of-gravityvertical position. Furthermore, from the initial (time Ts) totalcenter-of-gravity vertical position, the foot position/posture at thetime Ts (determined in step S200) and the like, the initial (time Ts)body vertical position Zs is determined using a model of the robot 1(the kinematics model represented by the formula 04, for example).Specifically, from the horizontal positions/postures of the supportingleg and the free leg at the time Ts, the vertical positions of thesupporting leg material particle 2 m and the free leg material particle2 m in the model shown in FIG. 10 are determined, and the verticalpositions and the initial (time Ts) total center-of-gravity positiondetermined as described above are applied to the formula 04, therebydetermining the vertical position of the body material particle 24 m (Zbin the formula 04). Then, from the vertical position of the bodymaterial particle 24 m and the body posture at the time Ts (0 in thisembodiment), the initial (time Ts) body vertical position Zs can bedetermined in an inverse operation manner. In this case also, a moreprecise model may be used to take into consideration the body horizontalposition and the arm posture to determine the initial body verticalposition Zs.

Finally, from the initial state of the foot position/posture determinedin step S200, the initial total center-of-gravity vertical velocitydetermined in step S206 and the like, the initial body vertical velocityis determined using a model of the robot 1 (for example, the kinematicsmodel represented by the formula 04). Specifically, the initial totalcenter-of-gravity vertical velocity determined based on the formula 13and the vertical velocities of the supporting leg material particle 2 mand the free leg material particle 2 m determined by the initial statesof the foot positions/postures of the supporting leg and free leg areapplied to a formula obtained by time-differentiating the both sides ofthe formula 04, thereby determining the vertical velocity of the bodymaterial particle 24 m. Then, from the vertical velocity of the bodymaterial particle 24 m and the initial state of the body posture angle(determined in step S200 or S208 described later), the body verticalvelocity is determined. Alternatively, such an initial body verticalvelocity that provides the initial total center-of-gravity verticalvelocity determined as described above may be determined using a moreprecise model of the robot 1 by taking into consideration the initialstate of the arm posture (determined in step S200), the initial state ofthe body horizontal position provisionally determined (the latest onesprovisionally determined in step S202 or step S216 or S218 describedlater) and the initial body vertical position determined as describedabove in addition to the initial state of the foot position/posture andthe initial total center-of-gravity vertical velocity.

More specifically, even if the model of the robot 1 is a complicated(precise) one such as shown in FIG. 11, since the robot 1 has sixdegrees of freedom for each leg, all the initial states of the robot aredetermined uniquely if the initial states of the foot position/posturetrajectory and the body position/posture trajectory (position/postureand the variation rates thereof) are given. Therefore, the initial totalcenter-of-gravity vertical velocity can be determined uniquely if thesame are given. Inversely, since the robot has six degrees of freedomfor each leg, even if one, concerning velocity, of the initial states ofthe foot position/posture trajectory and the body position/posturetrajectory (for example, the initial body vertical velocity) isundetermined, the undetermined initial state is determined uniquely ifthe initial total center-of-gravity vertical velocity is given.

After the processing of step S206, the process proceeds to step S208,where a provisional normal turning gait is generated. More specifically,based on the gait parameters of the normal gait determined in step S022in FIG. 12, the desired ZMP, the desired floor reaction force's verticalcomponent, the desired foot position/posture, the reference bodyposture, the desired arm posture and the floor reaction force'shorizontal component allowable range at instants between the initialtime Ts and the end time Te are determined successively. Then, in such amanner that the dynamical equilibrium conditions concerning the desiredZMP and the desired floor reaction force's vertical component and thecondition concerning the floor reaction force's horizontal componentallowable range are satisfied, the body position/posture is determinedusing the dynamics model (model shown in FIG. 10) assuming that the bodyhorizontal position/velocity (Xs, Vxs) and the body verticalposition/velocity (Zs, Vzs) are the initial (time Ts) states of the body24, thereby generating the gait from the time Ts to the end time Te. Inthis process, the body posture is generated so as to agree with thereference body posture as closely as possible.

The generation of the normal gait is performed only in the gaitgeneration device 100, and the result is not output to thecomposite-compliance determinator 104, described later, as a desiredvalue for driving the actual robot 1.

Details of a normal gait generation process using successivecalculation, which is the processing in step S208, will be describedbelow.

FIG. 20 is a subroutine flowchart showing the process.

In step S300, various initializations are performed. Specifically, theinitial time Ts is substituted for the provisional gait generation timek. Furthermore, the currently determined provisional values (Xs, Vxs)(determined in step S202 in FIG. 19 or steps S216 or S218 describedlater) are substituted for the body horizontal position/velocity, andthe latest values (Zs, Vzs) determined in step S206 are substituted forthe body vertical position/velocity. In addition, the reference bodyposture angle's initial value (reference body posture angle at the timeTs) is substituted for the desired body posture angle, and the referencebody posture angular velocity's initial value (reference body postureangular velocity at the time Ts) is substituted for the desired bodyposture angular velocity. In addition, the initial desired body postureangular velocity is eventually changed as described later, andtherefore, a value different from the reference body posture angularvelocity's initial value may be substituted for the desired body postureangular velocity.

Then, in step S304 after step S302, it is determined whether theprovisional gait generation time k precedes the end time of the gait ornot (whether k≦Ts+Tcyc). If the result of the determination is YES, theprocess proceeds to a gait instantaneous value determination subroutineof step S306, where gait instantaneous values are determined. Then, theprocess of the gait generation device 100 proceeds to step S308, wherethe provisional gait generation time k is incremented by Δk, and then,the process returns to step S304.

Here, Δk is an interval between provisional gait generations and maygenerally be the same as the control cycle Δt. If the dynamicalprecision of the provisional gait can be lowered, Δk may be set longerthan Δt for reducing the calculation amount.

If the result of the determination in step S304 is NO, the processproceeds to step S310. By the process described above, the normal gaitis generated from the start to the end thereof before the processproceeds to step S310.

Details of the gait instantaneous value determination subroutine of stepS306 will be described with reference to FIG. 21.

First, in step S400 in FIG. 21, based on the normal gait parameters(floor reaction force's vertical component trajectory parameters), thevalue (current time value) of the desired floor reaction force'svertical component at the time k shown in FIG. 16 is determined.Furthermore, in step S402, based on the normal gait parameters (ZMPtrajectory parameters), the value (current time value) of the desiredZMP trajectory at the time k shown in FIG. 18 is determined.

Then, the process proceeds to step S404, where based on the normal gaitparameters (the foot trajectory parameters, the reference body posturetrajectory parameters and the arm posture trajectory parameters), thevalues (current time values) of the desired feet positions/postures(desired foot positions/postures of the supporting leg and the freeleg), the reference body posture and the desired arm posture at the timek are determined. More specifically, as for the desired arm posture, thetotal center-of-gravity position of the both arms is determined,although the movement (swing movement) of the arm involving a change ofangular momentum about the vertical axis (or body trunk axis) is notdetermined yet. The current time value (value at the time k) of thedesired foot position/posture is determined in the same manner as thefoot position/posture at the initial time Ts determined in step S200 inFIG. 19.

Then, the process proceeds to step S406, where the value (current timevalue) of the total center-of-gravity vertical position/velocity at thetime k that provides the desired floor reaction force's verticalcomponent (i.e., brings the sum of the vertical inertial force of therobot 1 and the gravity into balance with the desired floor reactionforce's vertical component) is calculated. Specifically, based on theformulas 01 and 04 concerning the dynamics model in FIG. 10, forexample, the total center-of-gravity vertical position/velocity iscalculated. That is, according to the formulas 01 and 04, there isprovided a formula (equation of motion concerning the total center ofgravity of the robot 1 in the vertical direction) that represents thatthe total mass of the robot 1 multiplied by the sum of the totalcenter-of-gravity vertical acceleration due to the movement of the robot1 and the gravitational acceleration equals to the floor reactionforce's vertical component. Thus, from the formula and the desired floorreaction force's vertical component, the total center-of-gravityvertical acceleration is determined.

This formula itself generally holds without depending on the model ofthe robot 1. Then, the total vertical acceleration thus determined isintegrated, thereby calculating the total center-of-gravity verticalvelocity, and the total center-of-gravity vertical velocity is furtherintegrated, thereby calculating the total center-of-gravity verticalposition. More generally, these calculations are performed using thedynamical formulas represented by the following formulas 15 and 16(discrete versions of the Newton's equation of motion).

$\begin{matrix}{{{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu} k} = {{{total}\mspace{14mu}{center}\text{-}{of}\text{-}\;{gravity}\mspace{14mu}{vertical}\mspace{25mu}{velocity}\mspace{14mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\;\left( {k - {\Delta\; k}} \right)} + {\left( {\left( {{floor}\mspace{14mu}{reaction}\mspace{14mu}{{force}'}s\mspace{14mu}{vertical}\mspace{14mu}{component}\text{/}{total}\mspace{14mu}{mass}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{robot}} \right) + {{gravitational}\mspace{14mu}{acceleration}}} \right)*\Delta\;{k\left( {{The}\mspace{14mu}{gravitational}\mspace{14mu}{acceleration}\mspace{14mu}{is}\mspace{14mu} a\mspace{14mu}{negative}\mspace{14mu}{{value}.}} \right)}}}} & {{formula}\mspace{20mu} 15} \\{{{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}\mspace{20mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu} k} = {{{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}\mspace{20mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu}\left( {k - {\Delta\; k}} \right)} + {{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{at}\mspace{14mu}{the}\mspace{14mu}{time}\mspace{14mu} k*\Delta\; k}}} & {{formula}\mspace{20mu} 16}\end{matrix}$

Then, the process proceeds to step S408, where the body verticalposition that provides the total center-of-gravity vertical position iscalculated. Specifically, using the formula 04 concerning the model inFIG. 10, the total center-of-gravity vertical position is calculated.That is, from the current values of the desired foot positions/posturesof the supporting leg and the free leg, the vertical positions of thesupporting leg material particle 2 m and the free leg material particle2 m in the model in FIG. 10 are determined. Then, these verticalpositions of the supporting leg material particle 2 m and the free legmaterial particle 2 m and the current value of the totalcenter-of-gravity vertical position determined in step S407 are appliedto the formula 04, thereby determining the vertical position of the bodymaterial particle 24 m. Furthermore, the body vertical position isdetermined from the vertical position of the body material particle 24 mand the current value of the desired body posture angle (the currentreference body posture angle set in step S404 or the last time desiredbody posture angle (at the time k−Δk) determined in step S414 describedlater).

Alternatively, a more precise model (for example, a model in which amaterial particle is given to each link of the robot 1 as shown in FIG.11) may be used to determine the body vertical position. In this case,the body vertical position is determined in such a manner that the totalcenter-of-gravity vertical position agrees with the current time valueof the total center-of-gravity vertical position determined as describedabove. Here, the total center-of-gravity vertical position is determinedby the current time value of the desired feet positions/posturesdetermined as described above (value at the time k), the desired bodyposture at the time (k−Δk) (or current time value of the reference bodyposture determined as described above), the current time value of thedesired arm posture determined as described above (position of thecenter of gravity of the arms), the body horizontal position at the time(k−Δk) and the body vertical position to be determined.

In this case, the body posture and the body horizontal position at thetime k are undetermined, and therefore, the values thereof at the time(k−Δk) are used instead thereof. For a higher precision, the estimatedvalues thereof at the time k may be determined from the gait state atthe time (k−Δk) by extrapolation.

Then, the process proceeds to step S410, where based on the gaitparameters (parameters defining the floor reaction force's horizontalcomponent allowable range) determined in step S108 in FIG. 14, the value(current time value) of the floor reaction force's horizontal componentallowable range [Fxmin, Fxmax] at the time k shown in FIG. 17 isdetermined.

Then, the process proceeds to step S412, the current time values of thebody horizontal acceleration and the body posture angular accelerationare determined in such a manner that the dynamical equilibrium conditionconcerning the desired ZMP (condition that the horizontal component ofthe moment caused about the desired ZMP by the resultant force of theinertial force of the robot land the gravity is 0) is satisfied.However, the body horizontal acceleration and the body posture angularacceleration are determined in such a manner that the floor reactionforce's horizontal component Fx doesn't exceed the range [Fxmin, Fxmax]and an equal body posture angular velocity is provided at the start andthe end of the normal gait. Details thereof will be described below.

Since the instantaneous values (current time values) of the footposition/posture and the body vertical position have been determined asdescribed above at this point in time, the desired movement of the robot1 except for the degree of freedom of the movement of the arm thatinvolves a change of the angular momentum about the vertical axis can bedetermined uniquely by determining the body horizontal position and thebody posture angle. Therefore, if the body horizontal position and thebody posture angle are determined, all the quantities concerning thefloor reaction force are uniquely determined except for the moment ofthe floor reaction force about the vertical axis. In this embodiment,the desired floor reaction force's vertical component and the desiredZMP for the normal gait are defined by the floor reaction force'svertical component trajectory parameters and the desired ZMP trajectoryparameters determined in step S022 in FIG. 12, respectively. Therefore,of the quantities concerning the floor reaction force, only the floorreaction force's horizontal component is determined depending on thebody horizontal position and the body posture angle determined. Inaddition, as described above, since the robot 1 has six degrees offreedom for each leg, the positions/postures of the parts of each leg 2are uniquely determined from the desired foot position/posture and thedesired body position/posture. The degree of freedom of the movement ofthe arm that involves a change of the angular momentum about thevertical axis is used to cancel a spinning force, as described later.

In gait generation, if the desired ZMP is provided (the horizontalcomponent of the floor reaction force moment about the desired ZMP isbrought to 0) using primarily the body rotation mode rather than thebody translation mode, there arises a possibility that the body postureangle fluctuates too largely. Thus, to avoid this, the body translationmode should be used as far as circumstances permit. However, since thebody translation mode involves a change of the floor reaction force'shorizontal component, in the case where the floor reaction force'shorizontal component allowable range is narrow, there is a possibilitythat the robot slips if the body translation mode works intensely. Insuch a case, the body rotation mode has to be used. In particular, in aperiod in which the floor reaction force's horizontal componentallowable range is 0 as in the case of the running gait, such a gaitthat produce a floor reaction force's horizontal component cannot begenerated, and thus, the body rotation mode has to be used. In view ofthe points described above, in this embodiment, the body horizontalacceleration and the body posture angular acceleration are determinedaccording to the flowchart shown in FIG. 22.

First, in step S500, a time Tm is set. The time Tm is an instant whenthe floor reaction force's vertical component has increased to apredetermined level during a second turning gait after the initial timeTs and the floating period of a first turning gait. In addition, thereis set a time Ts2 at which the floor reaction force's vertical componenthas decreased to some degree in the latter half of the second turninggait. In addition, there is set a time Tm2 at which the floor reactionforce's vertical component has increased to a predetermined magnitude inthe next first turning gait after the floating period in the secondturning gait.

FIG. 16 shows these times. The time Tm is preferably set to the instantwhen substantially the whole surface of the sole of the supporting leg'sfoot 22 comes into contact with the floor or a time immediately afterthe instant. The same holds true for the time Tm2. Besides, the time Ts2is preferably set to the instant when the foot 22 having been in contactwith the floor at substantially the whole surface of the sole thereofcomes into contact with the floor only at the toe thereof or a timeimmediately before the instant.

As for the relationship between the desired ZMP shown in FIG. 18determined in step S110 in FIG. 14 and the times Tm, Ts2 and Tm2, it ispreferably that the time Tm is an instant when the desired ZMP, whichhas remained at an initial position, which is the position of the heelof the supporting leg's foot 22, until substantially the whole surfaceof the sole of the foot 22 comes into contact with the floor, startsmoving toward the middle of the supporting leg's foot 22. The time Ts2is preferably set to an instant when the desired ZMP is completelyshifted to the toe and only the toe of the supporting leg's foot 22 isin contact with the floor. In addition, the time Tm2 is preferably setto an instant when the desired ZMP, which has remained at an initialposition, which is the position of the heel of the supporting leg's foot22, until substantially the whole surface of the sole of the foot 22comes into contact with the floor, starts moving toward the middle ofthe supporting leg's foot 22.

The reason why these times are determined as described above will bedescribed later.

Then, in step S502, it is determined whether the present time k (valueindicated by a normal gait generation timer) lies between the time Tsand the time Tm or between the time Ts2 and the time Tm2. If the resultof the determination in step S502 is YES, the process proceeds to stepS504, and if the result is NO, the process proceeds to step S518.

In step S504, the body horizontal acceleration αtmp is determined whichis required to satisfy the current time desired ZMP (at the time k) inthe case where the angular acceleration for the body rotation mode isset to 0 to make the robot 1 move in the body translation mode from thelast time instantaneous gait state (gait state at the time k−1) of therobot 1. The value αtmp is determined using, for example, the formula 03concerning the dynamics model shown in FIG. 10. More specifically, forexample, the vertical accelerations of the supporting leg materialparticle 2 m and the free leg material particle 2 m at the present timek are determined using time series values of the desired footposition/posture determined before the present time k, and the verticalpositions of the supporting leg material particle 2 m and the free legmaterial particle 2 m are determined using the (current time) desiredfoot position/posture at the present time k. Besides, the verticalposition of the body material particle 24 m is determined using the(current time) floor reaction force's vertical position at the presenttime k, and the vertical acceleration of the body material particle 24 mat the present time k is determined using time series values of thedesired body vertical position determined before the present time k.Then, a formula obtained by substituting the determined values into theformula 03 and substituting 0 for My and d2θby/dt2 in the formula 03 issolved with respect to the body material particle's horizontalacceleration d2Xb/dt2, whereby the body material particle's horizontalacceleration d2Xt/dt2 is determined as the body horizontal accelerationαtmp. Note that it is also possible that, using a more strict dynamicsmodel, the body horizontal acceleration αtmp, which reduces a horizontalcomponent of a floor reaction moment about a desired ZMP to zero, isdetermined in a searching manner. Further, in this embodiment, since thereference body posture is the vertical posture and the body postureangular acceleration depending on the reference body posture is 0, thebody horizontal acceleration αtmp is determined assuming that theangular acceleration in the body rotation mode is 0. However, in thecase where the reference body posture trajectory parameters are set sothat the reference body posture varies and the reference body postureangular acceleration at the present time k which depends on thereference body posture has a value other than 0, the body horizontalacceleration αtmp may be determined using the dynamics model by settingthe angular acceleration for the body rotation mode to the value of thereference body posture angular acceleration other than 0 (for example,the body horizontal acceleration αtmp may be determined in the samemanner as described above by setting d2θby/dt2 in the formula 03 to thevalue of the reference body posture angular acceleration other than 0).

Then, the process proceeds to step S506, where the floor reactionforce's horizontal component Fxtmp at the time k in the case where thebody horizontal acceleration is αtmp is determined using the dynamicsmodel. In this embodiment, Fxtmp is determined using the formula 02 ofthe dynamics model. That is, Fxtmp is determined using the followingformula 17. In this formula, d2Xsup/dt2 and d2Xswg/dt2 represent thesupporting leg's foot material particle horizontal acceleration and thefree leg's foot material particle horizontal acceleration at the time k,respectively.Fxtmp=mb*αtmp+msup*d2Xsup/dt2+mswg*d2Xswg/dt2   formula 17

An example of Fxtmp thus determined is shown in FIG. 23. In FIG. 23, theshaded areas indicate that Fxtmp exceeds the floor reaction force'shorizontal component allowable range [Fxmin, Fxmax].

Then, the process proceeds to step S508, where the body horizontalacceleration α for the body translation mode, the floor reaction force'shorizontal component Fx caused by the body horizontal acceleration, andthe body angular acceleration β for the body rotation mode aredetermined in the following matter (S508 to S516).

That is,

If Fxtmp>Fxmax, the process proceeds to step S510, where Fx isdetermined by the following formula.Fx=Fxmax   formula 18If Fxtmp<Fxmin, the process proceeds to step S512, where Fx isdetermined by the following formula.Fx=Fxmin   formula 19Otherwise, that is, if Fxtmp lies within the floor reaction force'shorizontal component allowable range [Fxmin, Fxmax], the processproceeds to step S514, where Fx is determined by the following formula.Fx=Fxtmp   formula 20

In any of the cases, the process then proceeds to step S516, where thebody horizontal acceleration α and the body posture angular accelerationβ are determined by the following formulas.α=αtmp+(Fx−Fxtmp)/ΔFp   formula 21β=(αtmp−α)*ΔMp/ΔMr   formula 22

However, ΔFp, ΔMp and ΔMr are determined by the formulas 06, 07 and 09,respectively.

For a higher precision of the dynamical calculation, after the bodyangular acceleration β is determined as described above, the bodyhorizontal acceleration α for the body translation mode is preferablydetermined in an analytic or searching manner using a more precisedynamics model so that a composite movement of the body translation modeand the body rotation mode having the body angular acceleration βsatisfies the desired ZMP. As the determination method in a searchingmanner, the simplex method or a method of determining an affine Jacobian(sensitivity matrix) and determining a next candidate by the pseudoNewton method may be used.

Furthermore, in order to entirely prevent the floor reaction force'shorizontal component Fx from exceeding the floor reaction force'shorizontal component allowable range [Fxmin, Fxmax], a set of the bodyhorizontal acceleration α and the body angular acceleration β may bedetermined in a searching manner in such a manner that Fx=Fxmax and thehorizontal component of the floor reaction force moment about thedesired ZMP is 0 in step S510 or Fx=Fxmin and the horizontal componentof the floor reaction force moment about the desired ZMP is 0 in stepS512.

Fx thus determined is shown in FIG. 24. This Fx is Fxtmp that is limited(saturated) not to exceed the floor reaction force's horizontalcomponent allowable range [Fxmin, Fxmax]. More specifically, if Fxtmpassociated with the body horizontal acceleration αtmp of the bodytranslation mode falls within the allowable range [Fxmin, Fxmax], Fxtmpis adopted as Fx as it is. On the other hand, if Fxtmp associated withthe body horizontal acceleration αtmp of the body translation mode islarger than the upper limit of the allowable range [Fxmin, Fxmax] or issmaller than the lower limit thereof, Fx is forcedly limited to Fxmax orFxmin, respectively. In particular, during the floating period in therunning gait, since Fxmax and Fxmin are always 0 (Fxmax=Fxmin=0), Fx isalso 0 (Fx=0).

In addition, the body posture angular acceleration β thus determined isalso shown in FIG. 25. An insufficient floor reaction force moment dueto limitation of the acceleration for the body translation mode intendedfor preventing Fx caused in the body translation mode from exceeding theallowable range [Fxmin, Fxmax] is compensated for by the body rotationmode (specifically, the insufficient floor reaction force moment is theinertial force moment required for providing a horizontal component ofthe floor reaction force moment about the desired ZMP of 0 minus amoment component due to the limited body horizontal movement and themovements of the legs 2, 2). During the floating period of the runninggait, the body horizontal acceleration α of the body translation mode isalways limited to 0, and therefore, the insufficient floor reactionforce moment described above is compensated for only by the body postureangular acceleration β of the body rotation mode.

Described above is the processings performed in the case where the timek lies between the time Ts and the time Tm or between the time Ts2 andthe time Tm2.

If the result of the determination in step S502 is NO, the followingprocessings are performed. First, the process proceeds to step S518,where there is set a pattern of a ZMP-converted value of the floorreaction force moment which produces a body posture angular accelerationfor returning the body posture angular velocity to the initial value(which is the value at the time Ts if the present time k is ahead of thetime Ts2, or otherwise, the value at the time Ts2) by the time Ts2 ifthe present time k is ahead of the time Ts2, or otherwise, by the timeTe (the ZMP-converted value of the floor reaction force moment isreferred to as a body posture restoring moment ZMP-converted value andabbreviated as ZMPrec, hereinafter).

This will be described in detail below. The processings performed if thepresent time k is subsequent to the time Tm2 are the same as thoseperformed if the present time k is ahead of the time Ts2, and therefore,only the processings performed if the present time k is ahead of thetime Ts2 will be described.

It is to be considered to return the body posture angular velocity tothe initial value (value at the time Ts) by producing the body postureangular acceleration using the body rotation mode in a period from thetime Tm to the time Ts2. A body posture angular acceleration pattern forthis is denoted by β(k).

In the body rotation mode, when trying to produce the body postureangular acceleration Δ(k), a floor reaction force moment β(k)*ΔMr isproduced. As a result, assuming that the floor reaction force's verticalcomponent at that instant is Fz(k), the ZMP(k) calculated from themovement (rather than the desired ZMP) is shifted by ΔZMP determined bythe following formula.ΔZMP(k)=−β(k)*ΔMr/Fz(k)   formula 23

Therefore, if the patterns of ΔMr and Fz (k) are determined (known), thebody posture angular acceleration pattern that satisfies the formula 23can be produced by appropriately setting the pattern of ΔZMP(k), andthus, the body posture angular velocity can be returned to the initialvalue (value at the time Ts), that is, to the body posture angularvelocity in the initial state of the reference body posture trajectory(at the time Ts).

The “body posture restoring moment ZMP-converted value (ZMPrec) ” meansΔZMP(k) that is appropriately set in this way. Strictly speaking, whenthe body posture restoring moment ZMP-converted value is set using theformula 23, ΔMr varies. However, it may be set to an approximateconstant value. The reason for this is that the normal gait doesn'trequire a quite high dynamical precision because the normal gaitgenerated is a provisional one and the actual robot doesn't follow thegait.

FIG. 26 shows an example of ZMPrec. In FIG. 26, ZMPrec has a trapezoidalpattern. The times of the apexes of the trapezoidal pattern agree withthe times of the apexes of the desired ZMP pattern in the period fromthe time Tm to the time Ts2 (see FIG. 18). This is intended forsimplifying modification of the desired ZMP pattern of the current timegait, as described later. If ZMPrec is substituted for ΔZMP(k) in theformula 23, the following formula results.β(k)=−ZMPrec*Fz(k)/ΔMr   formula 24Therefore, β(k) determined by the formula 24 is as shown by the solidline in FIG. 27. The dotted line in FIG. 27 shows the body postureangular velocity from the time Ts to the time Tm (shown by the solidline in FIG. 25).

For the normal gait, the body posture angular velocity at the time Ts2preferably agrees with the body posture angular velocity at the time Ts.This is because such agreement provides reduced variation of the bodyposture angle.

Thus, in order to make the body posture angular velocity at the time Ts2agree with the body posture angular velocity at the time Ts, the bodyposture angular acceleration pattern is set in such a manner that theintegral of the body posture angular acceleration β for the period fromthe time Ts to the time Ts2 is 0. That is, the body posture angularacceleration pattern is set in such a manner that the integral of β(k)for the period from the time Tm to the time Ts2 (i.e., integral for thesolid line section in FIG. 27) equals to the integral of the bodyposture angular acceleration for the period from the time Ts to the timeTm (determined in steps S504 to S516 shown in FIG. 22) (i.e., integralfor the dotted line section in FIG. 27, in other words, the differencebetween the body posture angular velocity at the time Tm and the bodyposture angular velocity at the time Ts) multiplied by −1.

More specifically, in this embodiment, in the trapezoidal pattern ofZMPrec shown in FIG. 26, by assuming that the times of the apexes of thetrapezoid (determined based on the desired ZMP trajectory for the normalgait as described above) are known, and the height of the trapezoid isunknown, the height of the trapezoid of ZMPrec that satisfies theabove-described relationship (parameter that defines the ZMPrec pattern)can be determined.

The height of the trapezoid of ZMPrec for the first turning gait isreferred to as a first turning gait's body posture restoring moment'sZMP-converted value's trapezoid height acycl. The height of thetrapezoid of ZMPrec for the second turning gait is referred to as asecond turning gait's body posture restoring moment's ZMP-convertedvalue's trapezoid height acyc2. ZMPrec for the second turning gait is atrapezoidal pattern set in the period from the time Tm2 to the time Te.

Furthermore, as far as the gait parameters are not changed in theprocess of generation of one step of the current time gait, the ZMPrecpatterns for the period between the time Tm and the time Ts2 and theperiod between the time Tm2 and the time Te determined in step S518 arethe same (i.e., the same parameter values are calculated), andtherefore, the processing of step S518 may be performed only at thetimes Tm and Tm2.

Then, the process proceeds to step S520, where the instantaneous value(current time value) of the body posture restoring moment'sZMP-converted value ZMPrec at the time k is calculated based on theparameter (trapezoid height) determined as described above.

Then, the process proceeds to step S522, where the instantaneous value(current time value) β of the body posture angular acceleration patternat the time k is calculated using the formula 24.

Then, the process proceeds to step S524, where the body horizontalacceleration αtmp required for satisfying the current time (time k)desired ZMP in the case where the robot moves only in the bodytranslation mode without the movement in the body rotation mode from thelast time instantaneous desired gait state (desired gait state at thetime k−1) is determined using the dynamics model of the robot 1. Thiscalculation is performed in the same manner as in step S504.

Then, the process proceeds to step S526, where the body horizontalacceleration α for the body translation mode is calculated using thefollowing formula.α=αtmp−(ΔMr/ΔMp)*β  formula 25

Then, the process proceeds to step S528, where the floor reactionforce's horizontal component Fx at the time k for the body horizontalacceleration of α is determined using the following formula 26 similarto the formula 17.Fx=mb*α+msup*d2Xsup/dt2+mswg*d2Xswg/dt2   formula 26

Incidentally, for a higher precision of the dynamical calculation, afterthe body angular acceleration β is determined as described above,instead of calculating the body horizontal acceleration α using theformula 25 in step S526, the body horizontal acceleration α for the bodytranslation mode is preferably determined in an analytic or searchingmanner using a more precise dynamics model so that a composite movementof the body translation mode and the body rotation mode having the bodyangular acceleration β satisfies the desired ZMP, as supplementalydescribed concerning step S516.

Described above is the processings performed in the case where the timek is not included in any of the periods between the time Ts and the timeTm and between the time Ts2 and the time Tm2.

The floor reaction force's horizontal component Fx provided when theabove-described processings to the time Ts2 are completed is shown inFIG. 28. In addition, the floor reaction force's horizontal component Fxand the body posture angular acceleration β provided when theabove-described processings to the time Te are completed are shown inFIGS. 29 and 30, respectively. The processing of step S412 describedabove (subroutine for determining the body horizontal acceleration andthe body posture angular acceleration) is to determine the instantaneousvalues of the body horizontal acceleration and the body posture angularacceleration at the time k, rather than to collectively generate thetime series values thereof to the time Te.

In this embodiment, since the reference body posture is the verticalposture, and the body posture angular acceleration depending on thereference body posture is 0, the angular acceleration β for the bodyrotation mode determined as described above is regarded as the bodyposture angular acceleration determined in the processing of step S412.However, if the reference body posture trajectory parameters are set insuch a manner that the reference body posture varies, the sum of theangular acceleration β for the body rotation mode determined asdescribed above and the reference body posture angular accelerationshould be regarded as the body posture angular acceleration determinedin the processing of step S412.

The times Ts, Tm, Ts2 and Tm2 are set as described above to prevent thefloor reaction force's horizontal component Fx from exceeding theallowable range [Fxmin, Fxmax] even if the body posture angularacceleration β is produced so as to return the body posture angularvelocity to the initial angular velocity of the reference body posturetrajectory in the periods between the time Tm to the time Ts2 andbetween the time Tm2 and the time Te. In other words, during the periodsfrom the time Tm to the time Ts2 and from the time Tm2 to the time Te,the floor reaction force's horizontal component allowable range issufficiently wide, and therefore, even if the body posture angularacceleration β is produced to return the body posture angular velocityto the initial value while satisfying the desired ZMP, the floorreaction force's horizontal component Fx doesn't exceed the allowablerange.

Alternatively, rather than making the body posture angular velocity atthe time Ts agree with the body posture angular velocity at the time Ts,assuming that acycl and acyc2 have an equal value (assuming thatacyc1=acyc2), the value of acycl and acyc2 may be determined so as tomake the body posture angular velocity at the time Te agree with thebody posture angular velocity at the time Ts.

Then, the process proceeds to step S414 in FIG. 21, where the bodyhorizontal velocity is determined by integrating the body horizontalacceleration determined in step S412 (cumulatively summing the bodyhorizontal acceleration values from the time Ts to the present time k),and the body horizontal position (current time value) is determined byintegrating the body horizontal velocity (cumulatively summing the bodyhorizontal velocity values from the time Ts to the present time k). Inaddition, the body posture angular velocity is determined by integratingthe body posture angular acceleration determined in step S412(cumulatively summing the body posture angular acceleration values fromthe time Ts to the present time k), and the body posture angle (currenttime value) is determined by integrating the body posture angularvelocity (cumulatively summing the body posture angular velocity valuesfrom the time Ts to the present time k).

After the normal gait's instantaneous value determination subroutine ofstep S306 in FIG. 20 is conducted as described above, the processproceeds to step S308, where the value of the gait generation time k isincremented by the gait generation interval Δk. Then, the processreturns to step S304, and as far as the condition shown in step S304 issatisfied, the processings of steps S306 and S608 are repeated. If thecondition shown in step S304 is not satisfied, that is, if thegeneration of the provisional normal gait to the end thereof (to thetime Te=Ts+Tcyc) is completed, the process proceeds to step S310. InstepS310, the initial (time Ts) body posture angle and the initial (time Ts)body posture angular velocity are modified in accordance with thefollowing formulas based on the final (time Te) body posture angle ofthe provisional gait determined as described above or the like. Thismodification is intended for satisfying the boundary requirements of thenormal gait concerning the body posture angle and the angular velocitythereof (that is, both the body posture angle and the angular velocitythereof are the same at the start and the end of the normal gait). Inthis description, it is assumed that the gait of the robot 1 is one withwhich the robot 1 moves straight.

In this case, renewed values in the following formulas are the modifiedvalues.

$\begin{matrix}{{{{renewed}\mspace{14mu}{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}} = {{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}} - {\left( {{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}} - {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{11mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}}} \right)/{Tcyc}}}}\mspace{14mu}} & {{formula}\mspace{20mu} 30} \\{{{renewed}\mspace{14mu}{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} = {{initial}\;\left( {{time}\mspace{14mu}{Ts}} \right)\mspace{11mu}{reference}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}}} & {{formula}\mspace{20mu} 31}\end{matrix}$

Now, a reason why the initial state posture angular velocity is modifiedusing the formula 30 will be described below. For the normal gait, theinitial state posture angle and the angular velocity thereof have to bedetermined to avoid the movement of the robot 1 from being discontinuousat the boundaries between the gaits when the gait is repeated (tosatisfy the boundary requirements). In this case, the final body postureangular velocity for the provisional normal gait thus determined agreeswith the initial body posture angular velocity's initial value(reference body posture angular velocity's initial value) since the bodyposture angular acceleration pattern associated with the body posturerestoring moment ZMP-converted value ZMPrec is set. Therefore, if thefollowing formula, which is the remaining requirement, is satisfied, theabove-described requirements concerning the body posture angle and theangular velocity thereof are satisfied.final body posture angle=initial body posture angle   formula 32

In addition, there is a relationship expressed by the following formula.second order differential of the body posture angle=body posture angularacceleration   formula 33Therefore, second-order integrating the both sides of the formula 33 forthe period from the start to the end of the normal gait provides thefollowing relationship.

$\begin{matrix}{{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} = {{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} + {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}*{Tcyc}} + \mspace{14mu}{{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}}}} & {{{formula}\mspace{20mu} 34}\mspace{14mu}}\end{matrix}$

On the other hand, in normal gait generation, the horizontalacceleration (horizontal acceleration/deceleration) of the body 24 isadjusted using primarily the body translation mode for satisfying thedesired ZMP as described above. However, if the horizontal accelerationof the body 24 that satisfies the desired ZMP cannot produced adequately(if a sufficient friction force cannot be produced), the insufficientbody horizontal acceleration for the body translation mode iscompensated for by adjusting the angular acceleration of the bodyposture angle while keeping constant the total center-of-gravityacceleration using the body rotation mode.

The adjustment of the body posture angular acceleration using the bodyrotational movement mode is approximately equivalent to adjustment ofthe angular acceleration of the flywheel FH of the robot 1 shown in FIG.10. If the rotational velocity of the flywheel FH is close to 0, no gyroeffect occurs, and the force caused by the flywheel FH is determinedonly by the angular acceleration of the flywheel FH. Therefore, in therobot 1 having the flywheel FH in the body 24, even if the initial angleand the initial angular velocity of the flywheel FH vary slightly,substantially constant force is produced as far as the flywheel FH moveswith an angular acceleration of a same pattern. Therefore, in theformulas 01, 02 and 03, which are robot dynamics equations, the gyroeffect is neglected. Therefore, for the robot 1 according to thisembodiment, according to any of the formulas 01, 02 and 03 and a moregeneral and precise dynamics model, even when the initial body postureangle and the initial angular velocity vary slightly, substantially thesame resultant force of the inertial force and the gravity is producedas far as the body posture angle is changed with an angular accelerationof a same pattern while maintaining a constant total center-of-gravityacceleration (that is, as far as the body posture angle is changed withan angular acceleration of a same pattern in the body rotationalmovement mode). In other words, even if the initial body posture angleand the initial angular velocity vary slightly, the body posture angularacceleration for the gait generated according to the flowchart describedabove is not changed.

That is, the second order integral of the body posture angularacceleration in the formula 34 is independent of the initial bodyposture angle and the initial angular velocity. That is, the secondorder integral of the body posture angular acceleration in the formula34 can be treated as a constant value regardless of the values of theinitial body posture angle and the initial angular velocity.

Since the final-body posture angle is the final body posture angle forthe provisional gait when the value of the initial body posture angle isthe initial body posture angle for the provisional gait, and the valueof the initial body posture angular velocity is the initial body postureangular velocity for the provisional gait, applying this relationship tothe formula 34 results in the following formula.

$\begin{matrix}{{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}} = {{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}}\; + {{second}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}} + {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}*{Tcyc}}}} & {{formula}\mspace{14mu} 35}\end{matrix}$Thus, the following formula results.

$\begin{matrix}{{{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}} = {\left( {{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}} - {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}}} \right) - {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}*{Tcyc}}}} & {{formula}\mspace{20mu} 36}\end{matrix}$Since, from the above discussion, it is seen that the second orderintegral of the body posture angular acceleration can be treated as aconstant (the second order integral of the body posture angularacceleration is independent of the initial body posture angle and theinitial angular velocity), substituting the above formula into theformula 34 results in the following formula.

$\begin{matrix}{{{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} = {{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} + \left( {{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{11mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}} - \;{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}\mspace{11mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{20mu}{gait}}} \right) - \;{{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}\mspace{14mu}{for}\mspace{14mu}{the}\mspace{14mu}{provisional}\mspace{14mu}{gait}*{Tcyc}} + {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}*{Tcyc}}}}\;} & {{formula}\mspace{20mu} 37}\end{matrix}$From the formulas 37 and 32, the above-described formula 30 is provided.

In this embodiment, the initial body posture angle the initial bodyposture angle agrees with the initial value of the reference bodyposture angle as expressed by the formula 31. However, the initial bodyposture angle may be set so that the average value of the body postureangles for the normal gait agrees with the initial value of thereference body posture angle. Alternatively, the initial body postureangle may be set so that the average value of the maximum and theminimum of the body posture angle for the normal gait agrees with theinitial value of the reference body angle.

Furthermore, while a case where the robot 1 moves only straight isdescribed above, when determining a normal gait including a turningmovement, the robot 1 travels in different directions at the start andthe end of the normal gait. Therefore, the initial body posture angularvelocity depends on the initial body posture angle. Therefore, theinitial body posture angle and the initial angular velocity have to bedetermined considering this fact. In this case, for example, the initialbody posture angle and the initial body posture angular velocity may beupdated so that the following formulas 37a and 37b are satisfied.

$\begin{matrix}{{{{final}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}} - {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angle}}}\; = \mspace{11mu}{{{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}\mspace{14mu}{determined}\mspace{14mu}{so}\mspace{14mu}{as}\mspace{14mu}{to}\mspace{14mu}{satisfy}\mspace{14mu}{the}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{{force}'}s\mspace{14mu}{horizontal}\mspace{14mu}{component}\mspace{14mu}{allowable}\mspace{14mu}{range}} + {{second}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}\mspace{14mu}{caused}\mspace{14mu}{by}\mspace{14mu}{ZMPrec}} + {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{11mu}{velocity}*{period}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{normal}\mspace{14mu}{gait}}}} & {{formula}\mspace{20mu} 37\; a} \\{{{{{f{inal}}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{velocity}}\; - {{initial}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{20mu}{velocity}}} = {{{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}\mspace{14mu}{determined}\mspace{14mu}{so}\mspace{14mu}{as}\mspace{14mu}{to}\mspace{14mu}{satisfy}\mspace{14mu}{the}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{{force}'}s\mspace{14mu}{horizontal}\mspace{14mu}{component}\mspace{14mu}{allowable}\mspace{14mu}{range}} + {{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{body}\mspace{14mu}{posture}\mspace{14mu}{angular}\mspace{14mu}{acceleration}\mspace{14mu}{caused}\mspace{14mu}{by}\mspace{14mu}{ZMPrec}}}}\;} & {{formula}\mspace{20mu} 37\; b}\end{matrix}$

For the formulas 37a and 37b, the integral time for the first term inthe right side thereof is a sum of the period from the time Ts to thetime Tm and the period from the time Ts2 to the time Tm2, and theintegral time for the second term in the right side thereof is a sum ofthe period from the time Tm to the time Ts2 and the period from the timeTm2 to the time Te.

More specifically, in the normal gait, the initial state posture angleand the initial state angular velocity seen from the first turninggait's supporting leg coordinate system (next time gait's supporting legcoordinate system) have to agree with the final body posture angle andthe final angular velocity seen from the next first turning gait'ssupporting leg coordinate system (next but two gait's supporting legcoordinate system), respectively. Thus, in this embodiment, the renewedinitial body posture angle is determined by the formula 31, and therenewed initial body posture angle and a value seen from the nextturning gait's supporting leg coordinate system derived from the renewedinitial body posture angle by coordinate transformation thereof using amatrix corresponding to the total turning angle of the robot 1 in thenormal gait (turning angle about the vertical axis) (rotating coordinatetransformation matrix) are substituted for the initial body postureangle and the final body posture angle in the left side of the formula37a, respectively. Besides, as the body posture angular accelerationconcerning the integration in the first term of the right side of eachof the formulas 37a and 37b, the one determined successively in stepS516 in FIG. 22 is used.

Then, assuming that the initial body posture angular velocity in theformulas 37a and 37b and the trapezoid height of ZMPrec (the trapezoidalpattern shown in FIG. 26) concerning the integration in the second termof the right side of the formulas 37a and 37b are unknown quantities(where the times of the apexes of the ZMPrec trapezoidal pattern arepreviously determined, and the trapezoid height acycl of ZMPrec for thefirst turning gait equals to the trapezoid height acyc2 of ZMPrec forthe second turning gait), the simultaneous equations 37a and 37bincluding these unknown quantities are solved to determine the initialbody posture angular velocity as the renewed initial body postureangular velocity. In this case, the final body posture angular velocityin the formula 37b is a value seen from the next time gait's supportingleg coordinate system derived from the unknown initial body postureangular velocity by coordinate transformation using the matrixcorresponding to the total turning angle in the normal gait.

In the case where the robot 1 makes a movement including turning, therenewed initial body posture angle and the renewed initial angularvelocity may be determined as described above.

The initial body posture angular velocity that satisfies the boundaryrequirements of the normal gait may be determined in a searching manner.

After the processing of step S310 in FIG. 20 is completed, the processproceeds to step S210 in FIG. 19, where the final body horizontalposition/velocity for the gait generated (provisional normal gait) areconverted into values seen from a supporting leg coordinate systemassociated with the supporting leg at that instant (that is, X″′, Y″′,Z″′ coordinate system in FIG. 31), and the values are denoted by (Xe,Vxe) where Xe denotes a final body horizontal position and Vxe denotes afinal body horizontal velocity.

Then, the process proceeds to step S212, where the difference betweenthe initial body horizontal position/velocity (Xs, Vxs) and the finalbody horizontal position/velocity (Xe, Vxe) is calculated as shown inthe drawing. The difference (Xs−Xe, Vxs−Vxe) is referred to as a bodyhorizontal position/velocity boundary requirement error (errx, errvx).Since the boundary requirements have to be satisfied in the normal gait,(xs, Vxs) has to agree with (Xe, Vxe). Therefore, the body horizontalposition/velocity boundary requirement error (errx, errvx) has to be 0or approximately 0. In this embodiment, (Xs, Vxs) that provides a bodyhorizontal position/velocity boundary requirement error (errx, errvx) ofapproximately 0 is determined in a searching manner as described below.

Then, the process proceeds to step S214, where it is determined whetherthe calculated body horizontal position/velocity boundary requirementerror (errx, errvx) falls within an allowable range previouslyappropriately set. Instead of setting the allowable range for the bodyhorizontal position/velocity boundary requirement error as describedabove, it may be determined whether the difference between the initialdivergence component (Xs+Vxs/ω0) and the final divergence component(Xe+Vxe/ω0) and the difference between the initial convergence-component(Xs−Vxs/ω0) and the final convergence component (Xe−Vxe/ω0) fall withinrespective allowable ranges. As described earlier, ω0 is a predeterminedvalue.

If the result of the determination in step S214 is NO, the processproceeds to step S216. In step S216, a plurality of (two, in thisembodiment) initial value candidates (Xs+ΔXs, Vxs), (Xs, Vxs+ΔVxs) aredetermined in the vicinity of (Xs, Vxs). Here, ΔXs and ΔVxs mean apredetermined small variations of Xs and Vxs, respectively. Assumingthat each of these initial value candidates is an initial state of thebody horizontal position/velocity, a normal gait is generated using gaitparameters in the same manner as in the processing of step S208.Furthermore, values (Xe+ΔXe1, Vxe+ΔVxe1) and (Xe+ΔXe2, Vxe+ΔVxe2) seenfrom the supporting leg coordinate system (X″′, Y″′, z″′ coordinatesystem in FIG. 31) associated with the supporting leg at that instantconverted from the final body position/velocity of the generated normalgait are determined. Here, (Xe+ΔXe1, Vxe+ΔVxe1) indicates the final bodyposition/velocity corresponding to (Xs+ΔXs, Vxs), and (Xe+ΔXe2,Vxe+ΔVxe2) indicates the final body position/velocity corresponding to(Xs, Vxs+ΔVxs). In this processing of normal gait (provisional gait)generation, the initial states (states at the time Ts) of the variablesother than the body horizontal position/velocity may be set the same asin the case where the initial value candidate of the body horizontalposition/velocity is (Xs, Vxs), for example. In step S216, in addition,the difference between each initial value candidate and the final bodyposition/velocity corresponding thereto, that is, the body horizontalposition/velocity boundary requirement error for each of the initialvalue candidates (Xs+ΔXs, Vxs) and (Xs, Vxs+ΔVxs) is determined in thesame processing as that of step S210.

Then, the process proceeds to step S218, where based on the bodyhorizontal position/velocity boundary requirement error for each of (Xs,Vxs) and the initial value candidates in the vicinity thereof (Xs+ΔXs,Vxs) and (Xs, Vxs+ΔVxs), an initial value candidate following (Xs, Vxs)is determined by a searching method (for example, the simplex method ora method of determining an affine Jacobian (sensitivity matrix) anddetermining a next candidate by the steepest descent method). That is,from the body horizontal position/velocity boundary requirement errorfor each of (Xs, Vxs) and the initial value candidates in the vicinitythereof (Xs+ΔXs, Vxs) and (Xs, Vxs+ΔVxs), a sensitivity matrix thatindicates the degree of change of the body horizontal position/velocityboundary requirement error caused when the body horizontal position andthe body horizontal velocity are each slightly changed from the initialvalue candidates Xs and Vxs, respectively, and based on the sensitivitymatrix, an initial value candidate (Xs, Vxs) that provides furtherreduced body horizontal position/velocity boundary requirement error isnewly determined. Then, once the new initial value candidate (Xs, Vxs)for the body horizontal position/velocity is determined, the processreturns to step S206.

As far as the result of the determination in step S214 is NO, theprocessings described above (steps S206 to S218) are repeated. In thiscase, in step S300 (see FIG. 20) in the process of normal gaitgeneration (step S208) for the new initial value candidate (Xs, Vxs) ofthe body horizontal position/velocity, the initial value of the bodyposture angular velocity is set to the value determined in step S310(see FIG. 20) in the processing of step S208 for the last-time's initialvalue candidate (Xs, Vxs) of the body horizontal position/velocity,rather than the initial value of the reference body posture angularvelocity. Then, if the result of the determination in step S214 is YES,the repetition loop (step S204) is exited, and the process proceeds tostep S220. The provisional normal gait generated immediately beforeexiting the repetition loop of step S204 is adopted as the normal gaitthat satisfies the boundary requirements.

In step S220, the initial body horizontal position/velocity (X0, V0) atthe original initial time 0 (end time of the current time gait), theinitial body vertical position/velocity (Z0, Vz0) at the initial time 0,and the initial body posture angle and the initial angular velocity atthe initial time 0 are determined.

Specifically, (X0, V0) and (Z0, Vz0) are set to values seen from thesupporting leg coordinate system (X″′, Y″′, Z″′ coordinate system inFIG. 31) for the supporting leg for a step starting at the time Tcyc(that is, the second-time first-turning gait) which are converted fromthe body horizontal position/velocity and the body verticalposition/velocity determined at the instant when switching from thesecond turning gait to the second turning gait occurs in steps S408 andS414 in the normal gait instantaneous value determination subroutineshown in FIG. 21, that is, at the time k=Tcyc (time Te-Ts). Similarly,the initial state posture angle and the initial state angular velocityare set to values seen from the supporting leg coordinate system (X″′,Y″′, Z″′ coordinate system in FIG. 31) for the supporting leg for a stepstarting at the time Tcyc (that is, the second-time first turning gait)which are converted from the body posture angle and the angular velocitydetermined at the time k=Tcyc (time Te−Ts).

Then, the process proceeds to step S222, where the normal gait's initialdivergence component q[0] is determined by the following formula.q[0]=X0+V0/ω0  formula 40As described in the explanation about divergence, ω0 is a predeterminedvalue.

Then, the process proceeds to step S224, where the normal gait's initialdivergence component q[0] is converted into a value seen from thecurrent time gait's supporting leg coordinate system, and the resultingvalue is determined as q″[0]. The initial body verticalposition/velocity (Z0,Vz0) is converted into a value seen from thecurrent time gait's supporting leg coordinate system, and the resultingvalue is determined as (Z0″, Vz0″).

Specifically, (Z0″, Vz0″) agrees with the body verticalposition/velocity at the end of the second turning gait seen from thesecond turning gait's supporting leg coordinate system (X″, Y″, Z″coordinate system in FIG. 15). Besides, q″[0] also agrees with the finaldivergence component of the second turning gait seen from the secondturning gait's supporting leg coordinate system (X″, Y″, Z″ coordinatesystem in FIG. 15). Therefore, (Z0″, Vz0″) and q″[0] maybe calculatedusing these characteristics.

Then, the processing of step S024 in FIG. 12, that is, the subroutineprocessing for determining the initial states of the normal gait, iscompleted.

Then, the process proceeds to step S026 in FIG. 12, where the gaitparameters for the current time gait are determined (some of them areprovisionally determined). In step S026, a process described below isconducted in accordance with the flowchart shown in FIG. 32.

First, in step S600, the foot trajectory parameters for the current timegait are set in such a manner that the foot position/posture trajectoryfor the current time gait connects to the foot position/posturetrajectory for the normal gait.

Specifically, the current time gait's free leg's foot position/posture(initial value of the current time gait's free leg's footposition/posture) is set to the current free leg position/posture seenfrom the current-time gait's supporting leg coordinate system (free legposition/posture at the end of the last time gait). The supporting leg'sfoot position/posture at the start of the current time gait (initialvalue of the current time gait's supporting leg's foot position/posture)is set to the current supporting leg's foot position/posture seen fromthe current time gait's supporting leg coordinate system (supportingleg's foot position/posture at the end of the last time gait). Inaddition, the free leg's foot position/posture at the end of the currenttime gait is determined in accordance with the next time gait'ssupporting leg coordinate system seen from the current time gait'ssupporting leg coordinate system (that, is, in accordance with therequired value of the free leg landing position/posture for the firststep of the current time gait). That is, the free leg's footposition/posture at the end of the current time gait is determined insuch a manner that, when the free leg's foot 22 is rotated from the freeleg's foot position/posture at the end of the current time gait untilsubstantially the whole surface of the sole of the foot 22 comes intocontact with the floor while keeping the foot in contact with the floorwithout slipping, the representative point of the foot 22 agrees withthe origin of the next time gait's supporting leg coordinate system seenfrom the current time gait's supporting leg coordinate system.

At the end of the current time gait, the supporting leg's foot 22 isaway from the floor and floats in the air. To determine-the trajectoryafter the supporting leg's foot 22 takes off the floor, the expectedlanding position/posture of the supporting leg's foot is set. Theexpected landing position/posture of the supporting leg's foot is set inaccordance with the next but one time gait's supporting leg coordinatesystem seen from the current time gait's supporting leg coordinatesystem (that is, in accordance with the required value of the free leg'sfoot position/posture for the second step of the current time gait).More specifically, the expected landing position/posture of thesupporting leg's foot is set in such a manner that, when the foot 22 isrotated from the position/posture until substantially the whole surfaceof the sole of the foot 22 comes into contact with the floor whilekeeping the foot 22 in contact with the floor without slipping, therepresentative point of the foot 22 agrees with the origin of the nextbut one time gait's supporting leg coordinate system seen from thecurrent time gait's supporting leg coordinate system.

The supporting leg's foot position/posture at the end of the currenttime gait is determined using the finite duration settling filter togenerate, until the end of the current time gait, the footposition/posture trajectory that leads from the current supporting legposition/posture (supporting leg's foot position/posture at the start ofthe current time gait) to the expected foot landing position/postureassociated with the next time gait's supporting leg coordinate system(required value of the free leg's foot landing position/posture for thesecond step of the required parameters).

Then, the process proceeds to step S602, where the reference bodyposture trajectory parameters for the current time gait are determinedin the same manner as the first and second turning gaits of the normalgait. However, the parameters are set in such a manner that thereference body posture trajectory for the current time gait isseamlessly connected to the reference body posture trajectory for thenormal gait (that is, the reference body posture angle and the angularvelocity at the end of the current time gait agree with the referencebody posture angle and the angular velocity at the start of the normalgait, respectively). In this embodiment, both for the current time gaitand the normal gait, the reference body posture is constantly thevertical posture.

Then, the process proceeds to step S604, where the arm posturetrajectory parameters for the current time gait are determined in thesame manner as the first and second turning gaits of the normal gait.The parameters are set in such a manner that the arm posture trajectoryfor the current time gait is continuously connected to the arm posturetrajectory for the normal gait. The arm posture trajectory parametersdetermined in this step are movement parameters other than the parameterconcerning a change of the angular momentum of the arms about thevertical axis (or body trunk axis), which define the trajectory of theposition of the center of gravity of the arms, as with the normal gaitparameters determined in step S104 in FIG. 14.

Then, the process proceeds to step S606, where the floor reactionforce's vertical component trajectory parameters for the current timegait are set in such a manner that the floor reaction force's verticalcomponent trajectory defined by the parameters is substantiallycontinuous (i.e., has no step-wise discrete values) as shown in FIG. 6,as with the first and second turning gaits of the normal gait.

The floor reaction force's vertical component trajectory parameters areset in such a manner that both the total center-of-gravity verticalposition/posture and the floor reaction force's vertical componenttrajectory are continuously connected to those of the normal gait.

Specifically, based on the value (Z0″, Vz0″) seen from the current timegait's supporting leg coordinate system converted from the initial bodyvertical position/velocity for the normal gait finally determined in theprocessing of step S024 in FIG. 12 (processing for determining theinitial state of the normal gait), that is, the value (Z0″, Vz0″)determined in step S224 in FIG. 19 or the like, the initial totalcenter-of-gravity position/velocity for the normal gait seen from thecurrent time gait's supporting leg coordinate system is determined usingthe formula 04 (or kinematics model of the robot 1), for example.Specifically, the initial total center-of-gravity vertical position forthe normal gait seen from the current time gait's supporting legcoordinate system is determined by substituting, into the formula 04,the body material particle vertical position in the model in FIG. 10corresponding to the body vertical position Z0″ for the normal gaitdetermined in step S224 and the leg material particle vertical positionsfor the supporting leg and the free leg corresponding to the values seenin the current time gait's supporting leg coordinate system convertedfrom the foot positions thereof at the start of the normal gait.Besides, the initial total center-of-gravity vertical velocity for thenormal gait seen from the current time gait's supporting leg coordinatesystem is determined by substituting, into a formula obtained bydifferentiating the both sides of the formula 04, the body materialparticle vertical velocity in the model in FIG. 10 corresponding to thebody vertical velocity Vz0″ for the normal gait determined in step S224and the leg material particle vertical velocities for the supporting legand the free leg corresponding to the values seen in the current timegait's supporting leg coordinate system converted from the foot verticalvelocities thereof at the start of the normal gait. The calculation ofthe initial total center-of-gravity vertical position/velocity may beperformed using a more precise model.

Then, the initial total center-of-gravity vertical position/velocity forthe normal gait thus determined is substituted for the final totalcenter-of-gravity vertical position/velocity in the formula 13 and thefollowing formula 41, and the last-time desired gait instantaneousvalues (more specifically, values in the current time supporting legcoordinate system converted from the final states of the last timedesired gait) of the total center-of-gravity vertical position andvelocity are substituted for the initial total center-of-gravityvertical position and velocity in the formulas 13 and 41, therebydetermining the floor reaction force's vertical component pattern (morespecifically, parameter values) for the current time gait so that theformulas 13 and 41 are satisfied. Here, the integral values in theformulas 13 and 41 are the integral values for the period from the startto the end of the current time gait.

$\begin{matrix}{\left. {{{{final}\mspace{14mu}{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}} - {{initial}\mspace{14mu}{total}\mspace{14mu}{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}}} = {{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}\left( {{floor}\mspace{14mu}{reaction}\mspace{14mu}{force}}’ \right.s\mspace{14mu}{vertical}\mspace{14mu}{component}\text{/}{mass}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{robot}}} \right) + {{first}\mspace{14mu}{order}\mspace{14mu}{integral}\mspace{14mu}{of}\mspace{14mu}{the}\mspace{14mu}{gravitational}\mspace{14mu}{acceleration}}} & {{formula}\mspace{14mu} 41}\end{matrix}$

Here, the gravitational acceleration is a negative value.

More specifically, first, assuming that at least two parameters of thefloor reaction force's vertical component parameters (times of apexes orthe like) that define the floor reaction force's vertical componentpattern as shown in FIG. 6 are unknown variables, the value of theunknown variables are determined by solving the simultaneous equationscomprising the formulas 13 and 41.

As the floor reaction force's vertical component parameters assumed tobe unknown variables, the height (peak value of the floor reactionforce's vertical component) and the width (duration of the one legsupporting period) of the trapezoid in FIG. 6 may be adopted. In thiscase, the gradients of the sides of the trapezoid in FIG. 6 are set tovalues predetermined in accordance with the period of the current timegait or the like, or the times of the apexes of the floor reactionforce's vertical component pattern excluding the time of shifting fromthe one leg supporting period to the floating period occurs are set tovalues predetermined in accordance with the period of the current timegait or the like. Incidentally, if there is only one unknown variable,in general, there is no solution that satisfies the formulas 13 and 41.

Then, the process proceeds to step S608, where the floor reactionforce's horizontal component allowable range [Fxmin, Fxmax](specifically, parameters for defining the pattern of the floor reactionforce's horizontal component allowable range) is determined in the samemanner as the first and second turning gaits of the normal gait. Forexample, the floor reaction force's horizontal component allowable rangehaving a pattern shown in FIG. 33 is set. In this embodiment, the floorreaction force's horizontal component allowable range is set based onthe formula 12 in accordance with the floor reaction force's verticalcomponent pattern previously determined in step S606.

Then, the process proceeds to step S610, where the ZMP trajectory forthe current time gait (specifically, parameters defining the ZMPtrajectory, such as times or positions of the apexes of the trajectory)is set as shown in FIG. 7 to have a high stability margin and not tochange abruptly, as with the first and second turning gaits of thenormal gait. The parameters are set in such a manner that the ZMPtrajectory for the current time gait is seamlessly connected to the ZMPtrajectory for the normal gait. That is, the ZMP trajectory parametersare determined in such a manner that the position of the ZMP at the endof the current time gait agrees with the ZMP position at the start ofthe normal gait. In this case, for the running gait, the times orpositions of the apexes of the ZMP trajectory in the one leg supportingperiod may be set in the same manner as the ZMP trajectory parametersfor the normal gait described above. And, the ZMP trajectory parametersare set in such a manner that the desired ZMP trajectory in the floatingperiod linearly continuously change from the start of the floatingperiod to the ZMP position at the start of the normal gait.

Here, the ZMP trajectory parameters for the current time gait determinedin step S610 are provisional ones and to be corrected as describedlater. Thus, the ZMP trajectory for the current time gait thus set isreferred to as a provisional desired ZMP trajectory for the current timegait hereinafter.

Finally, the process proceeds to step S612, where a body posture anglerestoring period [Ta, Tb] is set. The body posture angle restoring starttime Ta corresponds to the time Tm in the second turning gait of thenormal gait, and the body posture angle restoring end time Tbcorresponds to the time Ts2 in the second turning gait of the normalgait. These times Ta and Tb are set in the same manner as the times Tmand Ts2, respectively.

Returning to FIG. 12, after the processing of step S026 (processing ofdetermining the gait parameters for the current time gait) is performedas described above, the process proceeds to step S028, where the gaitparameters for the current time gait (ZMP trajectory parameters) arecorrected. In this processing, the ZMP trajectory parameters arecorrected to make the body position/posture trajectory continuous withthe normal gait or bring the same close to the normal gait.

FIG. 34 is a subroutine flowchart showing the processing.

First, the process proceeds to step S702 via step S700, where based onthe provisional desired ZMP pattern and the other current time gaitparameters, a provisional current time gait to the end time of thecurrent time gait is provisionally generated.

In step S702, a process described below is conducted in accordance withthe flowchart shown in FIG. 35.

In step S800, various initializations are performed. Specifically, 0 issubstituted for the provisional gait generation time k. In addition,values in the current time supporting leg coordinate system convertedfrom the final states of the last time desired gait (more specifically,final values of the gait states including the body horizontalposition/velocity, the body vertical position/velocity, the body postureangle and the angular velocity, and the desired foot position/postureand the arm desired posture) are used as the current time gait's initialstates.

Then, in step S804 after step S802, it is determined whether theprovisional gait generation time k precedes the end time Tcurr of thecurrent time gait or not (whether k≦Tcurr). If the result of thedetermination is YES, the process proceeds to a current time gaitinstantaneous value determination subroutine of step S806, whereinstantaneous values for the current gait at the time k are determined.Then, the process proceeds to step S808, where the provisional gaitgeneration time k is incremented by Δk, and then, the process returns tostep S804.

If the result of the determination in step S804 is NO, the process shownin the flowchart in FIG. 35 is completed.

By the process described above, the provisional current gait isgenerated from the start to the end thereof.

In the gait instantaneous value determination subroutine in step S806,the process shown in FIG. 36 is performed. This process will bedescribed below.

First, in step S900, based on the floor reaction force's verticalcomponent trajectory parameters of the current time gait parameters, thevalue (current time value) of the desired floor reaction force'svertical component at the time k shown in FIG. 6 is determined. Then, instep S902, based on the ZMP trajectory parameters of the current timegait parameters, the value (current time value) of the desired ZMPtrajectory (provisional desired ZMP trajectory) at the time k shown inFIG. 7 is determined.

Then, the process proceeds to step S904, where based on the current timegait parameters (the foot trajectory parameters, the reference bodyposture trajectory parameters and the arm posture trajectoryparameters), the values (current time values) of the desired feetpositions/postures, the reference body posture and the desired armposture at the time k are determined. However, as for the desired armposture, while the total arm center-of-gravity position is determined,the degree of freedom of the movement that involves a change of angularmomentum about the vertical axis (or the body trunk axis) is notdetermined yet. As in the normal gait, the desired foot position/posturetrajectory and the floor reaction force's vertical component trajectoryfor the current time gait are independently determined in accordancewith the foot trajectory parameters and the floor reaction force'svertical component trajectory parameters determined in the flowchart inFIG. 32, respectively.

Then, the process proceeds to step S906, where the totalcenter-of-gravity vertical position at the time k that provides thecurrent time value of the desired floor reaction force's verticalcomponent determined in step S900 (i.e., brings the sum of the verticalinertial force of the robot 1 and gravity into balance with the desiredfloor reaction force's vertical component) is calculated. Specifically,this calculation is performed in the same manner as the processing instep S406 in FIG. 21.

Then, the process proceeds to step S908, where the current time value ofthe body vertical position that provides the total center-of-gravityvertical position thus determined is calculated. Specifically, thiscalculation is performed in the same manner as the processing in stepS408 in FIG. 21.

Then, the process proceeds to step S910, where based on the parametersof the floor reaction force's horizontal component allowable rangedetermined in step S608 in FIG. 32, the value (current time value) ofthe floor reaction force's horizontal component allowable range [Fxmin,Fxmax] at the time k shown in FIG. 33 is determined.

Then, the process proceeds to step S912, where the body horizontalacceleration and the body posture angular acceleration for the currenttime provisional gait are determined so as to satisfy the desired ZMP(that is, the horizontal component of the moment about the desired ZMPis 0). However, these acceleration are determined in such a manner thatthe floor reaction force's horizontal component Fx doesn't exceed therange [Fxmin, Fxmax]. This process is slightly different from theprocess shown in the flowchart in FIG. 22, which illustrates theprocessing in step S412 in FIG. 21 in detail.

Specifically, in step S912, the process shown in FIG. 37 is performed.In the flowchart shown in FIG. 37, first in step S1000, it is determinedwhether or not the time k lies within the body posture angle restoringperiod [Ta, Tb] determined in step S612 in FIG. 32.

If the result of the determination is NO (the floor reaction force'shorizontal component allowable range is 0 or narrow), the processingsfrom step S1002 to step S1014 are performed. The processings from stepS1002 to step S1014 are the same as the processings from step S504 tostep S516 in FIG. 22 described above, and thus, description thereof isomitted.

If the result of the determination in step S1000 is YES, the processproceeds to step S1016, where the body posture restoring momentZMP-converted value pattern ZMPrec is set. In this case, unlike stepS518 in FIG. 22 concerning the normal gait generation, ZMPrec is set toa pattern of a constant value of 0 (that is, the height of thetrapezoidal pattern shown in FIG. 26 is 0). Then, the processings fromstep S1018 to step S1026 are performed. The processings from step S1018to step S1026 are the same as the processings from step S520 to stepS528 in FIG. 22 described above, and thus, description thereof isomitted. In the processings from step S1016 to step S1026, theinstantaneous value of the body posture restoring moment ZMP-convertedvalue ZMPrec is always 0, and therefore, the body posture angularacceleration β for the body rotation mode determined in step S1020 isalso 0. Therefore, assuming that β=0, only the processings in stepsS1022, S1024 and S1026 may be performed. If the result of thedetermination in step S1000 is YES, that is, during the body postureangle restoring period [Ta, Tb], β is 0 (β=0) as described above.Therefore, in step S912, in the body posture angle restoring period [Ta,Tb] (that is, a period in which the floor reaction force's horizontalcomponent allowable range is wide enough), a movement trajectory forbody posture change in the direction for restoring the body postureangular velocity is not generated, unlike the case of normal gaitgeneration.

In this embodiment, since the reference body posture is the verticalposture, and the body posture angular acceleration depending on thereference body posture is 0, the angular acceleration β for the bodyrotation mode determined as described above is regarded as the bodyposture angular acceleration determined in the processing in step S912.However, if the reference body posture trajectory parameters are set insuch a manner that the reference body posture varies, the sum of theangular acceleration β for the body rotation mode determined asdescribed above and the reference body posture angular accelerationshould be regarded as the body posture angular acceleration determinedin the processing of step S912.

Once the processing in step S912 in FIG. 36 is completed as describedabove, the process proceeds to step S914, where the body horizontalvelocity is determined by integrating the body horizontal accelerationdetermined in step S912 (cumulatively summing the body horizontalacceleration values from the start of the current time gait (time k=0)to the present time k), and the body horizontal position (current timevalue) is determined by integrating the body horizontal velocity(cumulatively summing the body horizontal velocity values from the startof the current time gait (time k=0) to the present time k). In addition,the body posture angular velocity is determined by integrating the bodyposture angular acceleration determined in step S912 (cumulativelysumming the body posture angular acceleration values from the start ofthe current time gait (time k=0) to the present time k), and the currenttime value of the body posture angle is determined by integrating thebody posture angular velocity (cumulatively summing the body postureangular velocity values from the start of the current time gait (timek=0) to the present time k). The processing in step S914 is the same asthe processing in step S414 in FIG. 21.

After the current time gait instantaneous value determination subroutineof step S806 in FIG. 35 is conducted as described above, the processproceeds to step S808, where the value of the gait generation time k isincremented by the gait generation interval Δk. Then, the processreturns to step S804, and as far as the condition shown in step S804 issatisfied, the processings of steps S806 and S808 are repeated. Then, ifthe condition shown in step S804 is not satisfied, that is, if theprovisional current time gait is generated to the end thereof, theprocess proceeds to step S704 in FIG. 34.

In step S704, from the body horizontal position/velocity (Xe, Vxe) atthe end of the current time gait determined in step S702 as describedabove, the final divergence component q0[k] (k=Tcurr) is determinedusing the formula shown in the drawing (formula 10).

Then, the process proceeds to step S706, where a final divergencecomponent error errq, which is the difference between the current timegait's final divergence component q0[k] and the normal gait's initialdivergence component q″ (determined in step S224 in FIG. 19), isdetermined using the formula shown in the drawing. Then, the processproceeds to step 708, where it is determined whether the finaldivergence component error errq thus determined falls within anallowable range (a range in the vicinity of 0) or not.

If the result of the determination in step S708 is NO, the processproceeds to step S710, where, assuming that a=Δa (Δa is a predeterminedsmall amount), based on a desired ZMP obtained by correcting the currentprovisional desired ZMP pattern to be trapezoidal in accordance with therelationship shown in FIG. 38, the provisional current time gait to theend thereof is calculated in the same manner as in step S702. Here, withreference to FIG. 38, “a” denotes the height of the trapezoidal patternfor correcting the provisional desired ZMP to make the current timegait's final divergence component agree with the normal gait's initialdivergence component as closely as possible (bring the body horizontalposition/posture trajectory for the current time gait close-to the bodyhorizontal position/posture trajectory for the normal gait). In thiscase, in this embodiment, the correction of the provisional desired ZMPis performed during a period in which substantially the whole surface ofthe sole of the supporting leg's foot 22 (whole sole contact period),that is, during a period in which the floor reaction force's horizontalcomponent allowable range is sufficiently wide, and the times of theapexes of the trapezoidal pattern are set to the times of the apexes ofthe provisional desired ZMP pattern in the whole sole contact period.The assumption that a=Δa in step S710 is intended for observing a changeof the final divergence component error errq occurring when the currentprovisional desired ZMP trajectory is corrected by a small amount usingthe trapezoidal pattern.

After the provisional current time gait obtained when the provisionaldesired ZMP trajectory is corrected on the assumption that a=Δa isgenerated to the end thereof in step S710, the process proceeds to stepS712, where based on the body horizontal position/velocity (Xe1, Vxe1)at the end of the provisional current time gait, the final divergencecomponent q1[k] for the provisional current time gait is determinedusing the formula shown in the drawing (formula 10).

In this embodiment, Δa is assumed to be an appropriately set smallconstant in step S710. However, Δa may be set to decrease as the finaldivergence component error errq decreases through repeated calculationsdescribed below. However, if Δa is a constant, the final divergencecomponent error errq can be made to fall within the allowable range byseveral repeated calculations.

Then, the process proceeds to step S714, where a parameter sensitivity r(rate of change of the final divergence component error with respect toΔa) is determined using the formula shown in the drawing. Then, theprocess proceeds to step S716, where a correction quantity in atrapezoidal pattern having a height of a (=−errq/r, which is a valueobtained by dividing the final divergence component error errqdetermined in step S706 by the parameter sensitivity r determined instep S714) is added to the provisional desired ZMP pattern in accordancewith the relationship shown in FIG. 38, thereby correcting theprovisional desired ZMP pattern (determining a new provisional desiredZMP pattern).

Then, the process returns to step S702. Then, as far as the result ofthe determination in step S708 is NO, the processings from steps S702 toS716 are repeated, and if the result of the determination in step S708is YES, the repetition loop (step S700) is exited, and the processproceeds to step S718.

In step S718, based on the difference between the final body postureangle for the provisional current time gait and the initial body postureangle for the normal gait, the difference between the final body postureangular velocity for the current time gait and the initial body postureangular velocity for the normal gait or the like, a pattern of the bodyposture restoring moment ZMP-converted value (ZMPrec) for the currenttime gait is determined in such a manner that the body posture angle forthe current time gait is brought close to the body posture angle for thenormal gait. ZMPrec determined in this step is used for correcting theprovisional desired ZMP to maintain the agreement between the currenttime gait's final divergence component and the normal gait's initialdivergence component (condition in step S708) even if a body postureangular acceleration is produced so as to connect the body posture angletrajectory to the normal gait (bring the body posture angle trajectoryclose to the normal gait) during a period in which the floor reactionforce's horizontal component allowable range is sufficiently wide (aperiod in the one leg supporting period) in the processing of generatingthe current time gait instantaneous values described later.

ZMPrec has a trapezoidal pattern as with that described concerning thenormal gait generation process and, specifically, is determined in thefollowing manner. That is, assuming that, in the trapezoidal pattern ofZMPrec shown in FIG. 26, the times of the apexes (folds) of thetrapezoid are known (specifically, the times of the apexes of thetrapezoid are adjusted to the times of apexes of the desired ZMP) andthe height of the trapezoid is unknown, the height (parameter) oftrapezoid of ZMPrec is determined as described below. However,concerning step S718, the times Tm and Ts2 in FIG. 26 are replaced withthe times Ta and Tb, respectively.

If the body posture restoring moment ZMP-converted pattern-has-only oneunknown parameter as described above, in general, both of the bodyposture angle and the body posture angular velocity of the current timegait cannot be seamlessly connected to those of the normal gait at theend of the current time gait. Thus, in this embodiment, the unknownparameter is determined in such a manner that the state of the generatedgait is gradually brought close to the state of the normal gait throughplural steps.

Incidentally, both of the body posture angle and the body postureangular velocity of the current time gait may be connected to those ofthe normal gait at the end of the current time gait under the conditionsthat the ZMPrec pattern for one gait is more complicated and two or moreunknown parameters are used. However, in such a case, there is apossibility that the ZMPrec pattern varies too largely in a zigzag.

In the following, a calculation principle will be described, and then, acalculation procedure will be described.

The difference between the final body posture angle for the provisionalcurrent time gait determined as described above on the assumption thatthe height of the trapezoidal ZMPrec pattern is 0 in step S702 and theinitial body posture angle for the normal gait, and the difference isdenoted by θerr. In addition, the difference between the final bodyposture angular velocity for the provisional current time gait and theinitial body posture angular velocity for the normal gait is determined,and the difference is denoted by vθerr.

Here, it is assumed-that the current time-gait is generated on theassumption that the height of the trapezoidal ZMPrec pattern is acertain value bcurr, and subsequently, the first turning gait isgenerated by the same algorithm as the current time gait. Here, it isassumed that the pattern of the body posture restoring momentZMP-converted value ZMPrec for the first turning gait is expressed by asum of the ZMPrec pattern for the first turning gait determined in stepS518 in FIG. 22 (trapezoidal pattern having a height of acycl shown inFIG. 26) and a certain value b1.

The gait thus generated is referred to as a ZMPrec-corrected gait, andthe final body posture angle and the final angular velocity (at the endof the first turning gait) are denoted by θ1 and vθ1, respectively.

The body posture angle and the angular velocity at the end of the firstturning gait of the original normal gait determined when the subroutinefor determining the initial states of the normal gait in step S024 aredenoted by θ1org and vθ1org, respectively (the original normal gait isone determined on the assumption that the initial body posture angle andthe initial angular velocity for the normal gait determined by theformulas 30 and 31 in step S310 are used as initial values, and thepattern determined in step S518 (trapezoidal pattern having a height ofacycl in FIG. 26) is used as the ZMPrec pattern).

Here, Δθ1 and Δvθ1 are defined as follows.Δθ1=θ1−θ1 org   formula 50Δvθ1=vθ1−vθ1 org   formula 51

Δθ1 and Δvθ1 represent differences in body posture angle and angularvelocity, respectively, between the ZMPrec-corrected gait and theoriginal normal gait at the time when the first turning gait isgenerated to the end thereof. If Δθ1 and Δvθ1 are 0, when the secondturning gait is generated subsequently to the ZMPrec-corrected gait bythe same algorithm as the current time gait on the assumption that theheight of the trapezoidal ZMPrec pattern is acyc2, the generated gaitagrees with the original normal gait.

Therefore, a current time gait's trapezoidal pattern height bcurr and afirst turning gait's trapezoidal pattern height b1 are determined sothat Δθ1 and Δvθ1 are 0, and the determined value bcurr is used finallyas the trapezoidal pattern height for the current time gait.

Since the dynamics model concerning the body posture angle of the robot1 has a linearity similar to that of the flywheel FH as shown in FIG.10, Δθ1 and Δvθ1 are related as follows with the current time gait'strapezoidal pattern height bcurr, the first turning gait's trapezoidalpattern height b1, the difference θerr between the final body postureangle for the provisional current time gait and the initial body postureangle for the normal gait, and the difference vθerr between the finalbody posture angular velocity for the provisional current time gait andthe initial body posture angular velocity for the normal gait.Δθ1=c11*bcurr+c12*b1+θerr+e1*vθerr  formula 52Δvθ1=c21*bcurr+c22*b1+e2*vθerr  formula 53Here, c11, c12, c21, c22, e1 and e2 are coefficients that are uniquelydetermined by the gait periods of the current time gait and the firstturning gait, parameters of the pattern of the body posture restoringmoment ZMP-converted value ZMPrec (in particular, parameters concerningtime), or the like.

Based on the principle described above, in the calculation procedure,the body posture angle difference θerr and the angular velocitydifference vθerr at the boundary between the provisional current timegait and the normal gait are first determined.

Then, the coefficients c11, c12, c21, c22, e1 and e2 of the formulas 52and 53 are determined based on the gait periods of the current time gaitand the first turning gait, parameters of the pattern of the bodyposture restoring moment ZMP-converted value ZMPrec (in particular,parameters concerning time), or the like.

Then, the current time gait's trapezoidal pattern height bcurr and thefirst turning gait's trapezoidal pattern height b1 are determined insuch a manner that the right sides of the formulas 52 and 53 are 0. Thatis, the simultaneous equations of the formulas 52 and 53 with the rightsides being 0 are solved to determined the values bcurr and b1.

Finally, the height of the trapezoidal pattern of the body posturerestoring moment ZMP-converted value (ZMPrec) for the current time gaitis set to the determined current time gait's trapezoidal pattern heightbcurr.

Then, the process proceeds to step S720, whereas a desired ZMP patternfor the current time gait, a pattern is determined which is a sum of thecurrent provisional desired ZMP pattern (provisional desired ZMP patternwhen the repetition loop in step S700 is exited) and the body posturerestoring moment ZMP-converted value pattern determined as describedabove in step S718. This processing is the same as the processing ofadding the trapezoidal pattern having a height of Δa to the provisionaldesired ZMP pattern in step S710.

A reason why the body posture restoring moment ZMP-converted valuepattern is added to the provisional desired ZMP pattern will bedescribed below.

The provisional current time gait generated in the loop in step S700 isgenerated on the assumption that the body posture restoring momentZMP-converted value ZMPrec is 0 (the height parameter of the trapezoidalZMPrec pattern is 0) as described above. For the provisional currenttime gait thus finally generated in the loop in step S700, while thebody position/velocity is continuous to or close to that for the normalgait, the body posture angle is shifted from the body posture angle forthe normal gait or possibly diverges.

The body posture restoring moment ZMP-converted value pattern determinedin step S718 is one that produces such a body posture angularacceleration that brings the shift of the body posture angle from thatfor the normal gait close to 0.

However, if the body posture angular acceleration according to the bodyposture restoring moment ZMP-converted value pattern determined in stepS718 is produced without correcting the provisional desired ZMP patternresulting from the loop in step S700, the body horizontal positiontrajectory has to be shifted from the body horizontal positiontrajectory for the provisional current time gait in order to satisfy thedynamical equilibrium condition (that the moments applied to the desiredZMP by the resultant force of gravity and the inertial force of therobot, except for the vertical moment, are 0). Thus, in this embodiment,the provisional desired ZMP pattern is corrected so that there is noneed to shift the body horizontal position trajectory from thatresulting from the loop in step S700.

If, besides the movement according to the provisional current time gait,the body posture angular acceleration according to the body posturerestoring moment ZMP-converted value pattern determined in step S718 isproduced, the ZMP (a point where the moments caused by gravity and theinertial force caused by a movement, except for the vertical moment, are0) is shifted by the body posture restoring moment ZMP-converted value.Therefore, if a pattern which is a sum of the provisional desired ZMPpattern and the body posture restoring moment ZMP-converted pattern isused as a desired ZMP pattern, and a current time gait that satisfiesthe desired ZMP pattern is generated while producing a body postureangular acceleration for the body rotation mode associated with the bodyposture restoring moment ZMP-converted value pattern determined in stepS718, a body translation movement similar to the provisional currenttime gait is provided.

Above described is a reason why the sum of the body posture restoringmoment ZMP-converted value pattern and the provisional desired ZMPpattern is used as the desired ZMP pattern.

Returning to FIG. 12, after correcting the current time gait parametersin step S028 as described above, or if the result of the determinationin S016 is NO, the process proceeds to step S030, where current timegait's instantaneous values are determined.

In step S030, the same processings as those in steps S900 to S910 inFIG. 36 are performed, and then, the processings in steps S1000 to S1026in FIG. 37, which is the subroutine of step S912, are performed. In thiscase, however, in step S1016 in FIG. 37, the body posture restoringmoment ZMP-converted value (ZMPrec) pattern is not set to 0 but to bethe body posture restoring moment ZMP-converted value (ZMPrec) patternset in step S718 in FIG. 34. Then, the same processing as that in stepS914 in FIG. 36 is performed, and the process in step S030 in FIG. 12 iscompleted.

Then, the process proceeds to step S032, where an arm movement thatcancels the spinning force (that allows the floor reaction force'svertical moment caused about the desired ZMP by movements of parts,other than the arms, of the robot 1 to be substantially 0) isdetermined. Specifically, the floor reaction force moment's verticalcomponent trajectory in the desired ZMP in the case where the arms don'tswing is determined. (More strictly, values obtained by inverting thesigns of the instantaneous values of the vertical component trajectoryof the moment applied to the desired ZMP by the resultant force ofgravity and the inertial force of the robot in the case where the gaitis generated without the arms swinging are determined.) That is, aninstantaneous value is determined for the floor reaction force momentvertical component about the desired ZMP (instantaneous value) inbalance with the instantaneous value of the movement according to thegait generated in the processing in step S030 (excluding the arm swingmovement). Then, the instantaneous value is divided by the equivalentmoment of inertia the arm swing movement, thereby determining theangular acceleration of the arm swing movement required for cancelingthe spinning force. Incidentally, a too wide arm swing can be addressedby dividing the instantaneous value by a value larger than theequivalent moment of inertia.

Then, the angular acceleration is integrated two times, the resultingvalue is passed through a low cut filter for preventing the integralvalue from being too large, and the resulting angle is regarded as anarm swing movement angle. However, in the arm swing-movement, the leftand right arms are swung oppositely in the back-and-forth direction toprevent the center of gravity of the arms from varying. An arm swingmovement for canceling the spinning force may be generated for thenormal gait, and the arm swing movement for the current time gait bedetermined so as to connect to the arm swing movement.

Then, the process proceeds to step S034, where the gait generation timet is incremented by Δt. Then, the process returns to step S014, and thegait generation continues as described above.

Described above is the desired gait generation process conducted in thegait generation device 100.

The operation of the device according to this embodiment will be furtherdescribed with reference to FIG. 4. The gait generation device 100generates the desired gait as described above. The desired bodyposition/posture (trajectory) and the desired arm posture (trajectory)of the generated desired gait are transmitted to a robot geometricalmodel (inverse kinematics calculator) 102.

Besides, the desired foot position/posture (trajectory), the desired ZMPtrajectory (that is, the desired total floor reaction force centralpoint trajectory) and the desired total floor reaction force(trajectories) (specifically, the desired floor reaction force'svertical component and the desired floor reaction force's verticalcomponent) are transmitted to a composite-compliance operationdeterminator 104 and to a desired floor reaction force distributor 106.Then, the desired floor reaction force distributor 106 distributes thefloor reaction force among the feet 22R and 22L and determines thedesired each-foot floor reaction force central point and the desiredeach-foot floor reaction force. The desired each-foot floor reactionforce central point and the desired each-foot floor reaction force thusdetermined are transmitted to the composite-compliance operationdeterminator 104.

The composite-compliance operation determinator 104 transmits acorrected desired foot position/posture (trajectory) with deformationcompensation to the robot geometrical model 102. Upon receiving thedesired body position/posture (trajectory) and the corrected desiredfoot position/posture (trajectory) with deformation compensation, therobot geometrical model 102 calculates joint displacement commands(values) for the twelve joint (such as 10R(L)) of the legs 2, 2 andtransmits the commands to a displacement controller 108. Thedisplacement controller 108 controls the twelve joints of the robot 1 byfollowing the joint displacement commands (values) calculated by therobot geometrical model 102 as desired values. Besides, the robotgeometrical model 102 calculates displacement commands (values) for thearm joints that satisfy the desired arm posture and transmits thecommands to the displacement controller 108. The displacement controller108 controls the twelve joints of the arms of the robot 1 by followingthe joint displacement commands (values) calculated by the robotgeometrical model 102 as desired values.

The floor reaction force (specifically, actual each-foot floor reactionforce) produced in the robot 1 is detected by the six-axis force sensor34. The detection value is transmitted to the composite-complianceoperation determinator 104. In addition, the posture inclinationdeviations θerrx and θerry produced in the robot 1 are detected by theinclination sensor 36, and the detection values are transmitted to aposture stabilizing control calculator 112 (specifically, the deviationof the actual posture angle with respect to the desired body postureangle in the roll direction (about the X axis) is denoted by θerrx, andthe deviation of the actual posture angle with respect to the desiredbody posture angle in the pitch direction (about the Y axis) is denotedby θerry). Then, the posture stabilizing control calculator 112calculates the compensating total floor reaction force's moment aboutthe desired total floor reaction force central point (desired ZMP) forrestoring the body posture angle of the robot 1 to the desired bodyposture angle and transmits the calculation result to thecomposite-compliance operation determinator 104. Based on the inputvalue, the composite-compliance operation determinator 104 corrects thedesired floor reaction force. Specifically, the desired floor reactionforce is corrected so that the compensating total floor reaction force'smoment is applied about the desired total floor reaction force centralpoint (desired-ZMP).

The composite-compliance operation determinator 104 determines thecorrected desired foot position/posture (trajectory) with deformationcompensation in order for the states and floor reaction force of theactual robot calculated from the sensor detection values or the like toagree with the corrected desired floor reaction force. However, it isactually impossible that all the states agree with their respectivedesired values, and therefore, various trade-offs are made among thesestates so that each of them agrees with its desired value as closely aspossible. That is, a control deviation for each desired value isweighted, and the weighted average of the control deviation (or thesquare of the control deviation) is controlled to be minimum. Thus, theactual foot position/posture and the actual total floor reaction forceare controlled so as to generally agree with the desired footposition/posture and the desired total floor reaction force,respectively.

Since the present invention essentially concerns the gait generation forthe robot 1 using the gait generation device 100, and the configurationand operation of the composite-compliance operation determinator 104 orthe like are described in detail in Japanese Patent Laid-Open No.10-277969 previously filled by the applicants or the like, furtherdetails thereof will not be described herein.

In step S028, the current time gait is corrected in such a manner thatthe final divergence component of the current time gait agrees with avalue q″, which is the normal gait's initial divergence component q[0]seen from the current time gait's supporting leg coordinate system, asdescribed above.

Actually, the divergence component serves as an indicator for evaluatingwhether the body horizontal position for a current time gait convergesto that for a normal turning gait when the current time gait isgenerated using a dynamics model in accordance with current time gaitparameters, and successively, the normal turning gait is generated inaccordance with normal turning gait parameters. Essentially, thedivergence component has to be defined so that the final divergencecomponent of the current time gait agrees with a value q″, which is thenormal gait's initial divergence component q[0] seen from the currenttime gait's supporting leg coordinate system when the convergencedescribed above occurs.

Actually, the divergence component defined by the formula 10approximately satisfies this condition.

Therefore, it can be said that, in this embodiment, the current timegait parameters are corrected so that the body horizontal position forthe current time gait converges to (comes close to) that for the normalturning gait when the current time gait is generated using a dynamicsmodel in accordance with the current time gait parameters, andsuccessively, the normal turning gait is generated in accordance withnormal turning gait parameters.

The same is described in Japanese Patent Application No. 2000-352011.

In this embodiment, of the current time gait parameters, the desired ZMPpattern is particularly corrected to satisfy the condition (that thecurrent time gait comes close to the normal gait). Referring to FIG. 39,a trajectory denoted by symbol B indicates a body horizontal positiontrajectory generated in such a manner that the divergence components oftwo gaits agree with each other at the boundary of the gaits asdescribed above.

A trajectory denoted by symbol A indicates a body horizontal positiontrajectory resulting from generating a current time gait in such amanner that the body horizontal position/velocity agrees with that forthe normal turning gait at the boundary therebetween and then generatingnormal gaits repeatedly.

As shown in this drawing, the trajectory B generally doesn't agree withthe trajectory A at the boundary between the current time gait and thefirst normal turning gait. Then, however, the trajectory B graduallyconverges to (comes close to) the trajectory A and substantially agreeswith the trajectory A in the next normal turning gait cycle. Asdescribed above, as with the gait generation method involving agreementsabout both the position and velocity at the gait boundary, the gaitgeneration method involving only agreement about the divergencecomponent at the gait boundary can prevent a gait from diverging. Atrajectory denoted by symbol C indicates a trajectory generated withoutconsideration for these conditions. In this case, the generatedtrajectory diverges with time. Of course, both the agreements about boththe position and velocity may be achieved by using more complicateddesired ZMP pattern and adjusting a plurality of parameters. However, insuch a case, there is a possibility that a zigzag desired ZMP patternresults. Since agreements about both the position and velocity result inagreement about the divergence component, it can be said that the methodinvolving agreements about both the position and velocity is a specialexample of the method involving agreement about the divergencecomponent.

Furthermore, it can be said that, in this embodiment, the current timegait parameters are corrected so that the body posture angle for thecurrent time gait converges to (comes close to) or agree with the bodyposture angle for the normal turning gait when the current time gait isgenerated using a dynamics model in accordance with the current timegait parameters, and successively, the normal turning gait is generatedin accordance with normal turning gait parameters.

Since the gait generation device for the legged mobile robot accordingto this embodiment is configured as described above, strictly, thecurved relationship shown by the solid line in FIG. 41 is a relationshipbetween the final body horizontal position and final body horizontalvelocity for the current time gait which satisfies the condition thatthe body horizontal position for the current time gait converges to thatfor the normal turning gait when the current time gait is generatedusing a dynamics model in accordance with the current time gaitparameters, and successively, the normal turning gait is generated inaccordance with normal turning gait parameters. According to theessential definition of the divergence component, the value of thedivergence component has to be constant for any combination of the finalbody horizontal position and the final body horizontal velocity whichsatisfies the relationship represented by the solid line in FIG. 41. Inaddition, for making the divergence component a physically comprehensiveindicator, it is desirable that the final body horizontal position andthe divergence component have the same value when the final bodyhorizontal velocity is 0.

That is, it is desirable that the relationship shown by the solid linein FIG. 41 is represented by the following formula 60, and the followingformula 61 is satisfied, where f denotes a function for determining thedivergence component.f (final body horizontal position, final body horizontal velocity)=C (Cdenotes a constant)   formula 60f (final body horizontal position, 0)=final body horizontal position  formula 61

The value of the function f (final body horizontal position, final bodyhorizontal velocity) is the value of the divergence component.

The above-described formula 10, which defines the divergence component,is an approximate expression of the function f. In the case where thedivergence component defined by the formula 10 is a constant, the finalbody horizontal position and the final body horizontal velocity arerelated to each other as shown by the dotted line in FIG. 41, which isan approximate line of the solid line.

The function f representing the divergence component may be approximatedto a curve using a polynomial, rather than to a straight line.Alternatively, the function f may be converted into a map for storage.

For a higher approximation precision, the function f should be variedwith the normal gait parameters.

In the formula 10 defining the divergence component, the body positionand velocity may be replaced with the robot total center-of-gravityposition and velocity, respectively.

In this embodiment, to be readily understood, it is assumed that thefloor reaction force's horizontal component allowable range can be setseparately for the back-and-forth direction (X-axis direction) and thesideward direction (Y-axis direction). However, if the floor reactionforce's horizontal component allowable range is represented byrelational formulas for the back-and-forth direction and the sidewarddirection, a gait that avoids slipping can be generated.

For example, the allowable range may be a so-called friction circle asdescribed by the following formula.

$\begin{matrix}{\left. {\left. {\left. {\left. {\left( {X\mspace{14mu}{component}\mspace{14mu}{of}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{force}}’ \right. s\mspace{14mu}{horizontal}\mspace{14mu}{component}} \right)*\left( {X\mspace{14mu}{component}\mspace{14mu}{of}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{force}}’ \right. s\mspace{14mu}{horizontal}\mspace{14mu}{component}} \right) + {\left( {Y\mspace{14mu}{component}\mspace{14mu}{of}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{force}}’ \right. s\mspace{14mu}{horizontal}\mspace{14mu}{component}}} \right)*\left( {Y\mspace{14mu}{component}\mspace{14mu}{of}\mspace{14mu}{floor}\mspace{14mu}{reaction}\mspace{14mu}{force}}’ \right. s\mspace{14mu}{horizontal}\mspace{11mu}{component}} \right) \leq {\left( {{ka}*\mu*{Fz}} \right)*\left( {{ka}*\mu*{Fz}} \right)}} & {{formula}\mspace{14mu} 59}\end{matrix}$

Here, Fz denotes the desired floor reaction force's vertical component,μ denotes a friction coefficient, and ka denotes a positive constantequal to or smaller than 1.

However, in the case where the floor reaction force's horizontalcomponent allowable range is represented by the relational formulas forthe back-and-forth direction and the sideward direction as describedabove, the movement on the sagittal plane and the movement on thelateral plane have to be determined simultaneously or alternately so asto satisfy the allowable ranges for the directions simultaneously oralternately.

Since the sum of the total center-of-gravity vertical acceleration andthe gravitational acceleration of the robot is proportional to the floorreaction force's vertical component, a parameter prescribing the totalcenter-of-gravity vertical acceleration trajectory of the robot may beexplicitly set as a gait parameter, instead of the floor reactionforce's vertical component trajectory. The two are substantially thesame. Furthermore, a parameter prescribing the vertical accelerationtrajectory of a part whose behavior resembles that of the totalcenter-of-gravity trajectory of the robot may be set explicitly. Forexample, in the case where the mass of the legs is sufficiently smallerthan the mass of the body, the body vertical acceleration trajectory andthe total center-of-gravity vertical acceleration trajectory of robotare substantially the same or proportional to each other. Therefore, thebody vertical acceleration trajectory may be used instead of the floorreaction force's vertical component trajectory. Similarly, since floorreaction force's horizontal component and the total center-of-gravityhorizontal acceleration of the robot are proportional to each other, thetotal center-of-gravity horizontal acceleration of the robot and theallowable range thereof may be used instead of the floor reactionforce's horizontal component and the allowable range thereof in thisembodiment. Furthermore, a parameter concerning the horizontalacceleration trajectory of a part whose behavior resembles that of thetotal center-of-gravity horizontal trajectory of the robot may be setexplicitly. For example, in the case where the mass of the legs issufficiently smaller than the mass of the body, the body horizontalacceleration trajectory and the total center-of-gravity horizontalacceleration trajectory of the robot are substantially the same orproportional to each other. Therefore, the body horizontal accelerationand the allowable range thereof may be used instead of the floorreaction force's horizontal component and the allowable range thereof.

In order for the floor reaction force's horizontal component and thefloor reaction force's moment about the desired ZMP to have adequatevalues, two movement modes, that is, the body rotation mode and the bodytranslation mode are used in the embodiments described above. However,another movement mode may be used.

For example, as shown in FIG. 40, if the body posture is rotated aboutthe hip joint, the total center of gravity, as well as the angularmomentum about the total center of gravity, varies. Combining(synthesizing) this movement with the movement in the body translationmode by a predetermined ratio results in substantially the same movementin the body rotation mode, and no floor reaction force's horizontalcomponent occurs. Therefore, if this mode is regarded as the bodyrotation mode, a gait similar to those in the embodiments describedabove can be generated according to the algorithm in this embodiment.

Therefore, there is no need to have at least one movement mode thatproduces no floor reaction force's horizontal component. This is becauseany floor reaction force's horizontal component and floor reactionforce's moment about the desired ZMP can be produced for any combinationof movement modes as in the example described above, as far as the twomovement modes produce the floor reaction force's horizontal componentand the floor reaction force's moment about the desired ZMP in differentratios.

Alternatively, a movement mode other than those involving varying thebody posture may be used. However, it is preferable that a movement modeis chosen in which a minimum displacement produces a large floorreaction force's horizontal component or floor reaction force's momentabout the desired ZMP.

For example, a movement mode in which the left and right arms are swungin the same rotational direction, or a movement mode in which theposition of a foot not in contact with the floor (floating in the air)is brought into perturbation may be used. However, in the case where thefree leg trajectory is brought into perturbation, the amount ofperturbation should be reduced to approximately 0 by the timeimmediately before landing to avoid varying the landing position.

Alternatively, three or more movement modes may be used.

In this case, at least two of the chosen movement modes have to be onesthat produce the floor reaction force's horizontal component and thefloor reaction force's moment about the desired ZMP in different ratios.Otherwise, in general, the simultaneous equations would have nosolutions (the behavior for each movement mode cannot be determineduniquely).

Furthermore, preferably, a movement mode that varies the floor reactionforce's moment about the desired ZMP significantly and doesn't vary solargely the floor reaction force's horizontal component is combined witha movement mode that varies the floor reaction force's horizontalcomponent significantly and doesn't vary so largely the floor reactionforce's moment about the desired ZMP.

In other words, preferably, a movement mode that varies the angularmomentum adequately and doesn't vary so largely the total center ofgravity is combined with a movement mode that varies the total center ofgravity adequately and doesn't vary so largely the angular momentum.This is because such combination allows the displacements of themovement modes to be reduced.

Models other than the dynamics models used in the embodiments, such asthose described below, may be used.

-   1) A nonlinear model in which material particles are provided for a    plurality of links as shown in FIG. 11 (multi-mass model).-   2) A three-material-particle model disclosed in Japanese Patent    Application No. 2000-352011 filed by the applicants.-   3) A one-material-particle model in which only the body has a mass.-   4) A model which neglects the moment of the inertial force caused by    an angular momentum variation about the total center of gravity.-   5) A separate-type model which has a partial model representing a    relationship between the resultant force of gravity and the inertial    force (or the floor reaction force in balance therewith) and the    body translation movement and a partial model representing a    relationship between the resultant force and the body rotation    movement. For example, the material particles shown in FIG. 10    constitute the partial model representing a relationship between the    resultant force and the body translation movement, and the flywheel    shown in FIG. 10 constitutes the partial model representing a    relationship between the resultant force and the body rotation    movement.

In addition, the processings may be performed using only one model, ordifferent models may be used for the different processings. For example,since the normal gait is generated only to determine the final state ofthe current time gait, the required dynamics precision of the normalgait is lower than that of the current time gait. Therefore, forexample, while the dynamics model (model consisting of three materialparticles and a flywheel) shown in FIG. 10 is used in generation of thecurrent time gait, in generation of the normal gait (in particular,steps S408 and S412 in FIG. 21), a dynamics model which consists of thebody material particle 24 m corresponding to the body 24 and theflywheel FH, neglecting the masses of the legs 2, 2 (that is, a modelconsisting of one material particle and a flywheel, which results fromeliminating the leg material particles 2 m, 2 m from the model in FIG.10) may be used. In generation of the normal gait in this case, in theembodiments described above, the processings in steps S408 and S412 inFIG. 21 are performed assuming that the mass of the leg materialparticles 2 m, 2 m is 0. This allows calculation amount involved in thenormal gait generation to be significantly reduced.

In the embodiments described above, the block diagrams, the flowchartsand the algorithms may be altered into equivalent ones by changing thesequence of calculations. In addition, a low-pass filter may be insertedappropriately.

While the embodiments of the present invention has been describedconcerning a two-legged mobile robot, the present invention can beapplied to a legged robot having three or more legs.

Here, the process of determining the initial (time Ts) body verticalposition Zs in step S206 in FIG. 19 will be described supplementally.According to the process of determining the body height proposed by theapplicants in Japanese Patent Laid-Open No. 10-86080, the body verticalposition is determined in such a manner that the bending angle of theknees of the legs satisfies a certain relationship. However, as for thebody vertical position at the time 0 (that is, at the instant oflanding), it may be determined in such a manner that the bending angleof the knee of the leg just landing is a predetermined angle or fallswithin a predetermined angle range. This is because the capacity toabsorb the impact of landing primarily depends on the bending angle ofthe knee of the landing leg. Incidentally, if the bending angle of theknee is close to 0 (that is, the leg is almost fully stretched), thecapacity to absorb the impact of landing tends to be reduced. On theother hand, an excessive knee bending may results in an excessive torqueof the knee joint actuator.

Furthermore, in this embodiment, in step S206 in FIG. 19, the bodyvertical position at the instant of landing is determined in akinematical (geometrical) manner, and the body vertical position at anytime except for the instant of landing is determined based on thedesired vertical floor reaction force so as to satisfy the dynamicalcondition. However, more generally, the body vertical position at thetime when the leg is stretched to a maximum extent (in other words, theknee bending angle becomes closest to 0, or the distance between the hipjoint and the ankle joint is the largest), such as immediately beforeand after landing or taking off the floor, may be determine in akinematical (geometrical) manner, and the body vertical position at anyother time may be determined based on the desired vertical floorreaction force so as to satisfy the dynamical condition.

Instead of determining the initial states of the normal gait (including,primarily, initial body horizontal position/velocity and initial bodyvertical position/velocity) using a searching approach or usingpartially an analytic approach as in this embodiment, the initial statesof the normal gait may be previously calculated for various normal gaitparameters using these approaches, a relationship between the normalgait parameters and the initial states of the normal gait may be storedin the form of a map or approximate expression, and the initial valuesfor the normal gait may be determined based on the map or approximateexpression when the robot actually moves.

Furthermore, a function resulting from combination of the relationshiprepresented in a map or approximate expression and the function f may bestored in the form of a map or approximate expression. That is, afunction that determines the divergence component of the normal gaitdirectly from the normal gait parameters comprising the foot trajectoryparameters, the floor reaction force vertical trajectory parameters andthe like may be stored in the form of a map or approximate expression.For example, a normal gait is previously generated for each of sets of aplurality of representative normal gait parameters, initial states ofthe normal gait for each set of normal gait parameters (which aredetermined in step S024 in FIG. 12) are determined, and a maprepresenting a relationship between the normal gait parameters of eachset and the initial states of the normal gait is created. Then, whengenerating a desired gait, the initial states of the normal gait may bedetermined from the set of normal gait parameters which are selectedfrom the map or determined by interpolating the map. This eliminates theneed of generating a normal gait each time a current time gait isgenerated and allows calculation amount involved in the desired gaitgeneration to be significantly reduced.

In this embodiment, the desired ZMP parameter of the current time gaitis corrected to correct the current time gait to connect the currenttime gait to the normal gait (or to bring the current time gait close tothe normal gait). However, another parameter may be corrected.

For example, the trajectory of the floating free leg of the current timegait may be modified. In addition, for example, if the body horizontalposition is to be displaced rearward from that of the normal gait, thefree leg is moved forward quickly after taking off the floor to shiftthe free leg's center of gravity forward. This causes the bodyhorizontal position that satisfies the desired ZMP to move forwardacceleratedly. As a result, the body horizontal position is furthermoved forward at the end of the current time gait and thus is made toagree with that of the normal gait.

Alternatively, instead of correcting the desired ZMP parameter, theperiod of the current time gait maybe corrected. For example, if thebody horizontal position is to be displaced rearward from that of thenormal gait, the period of the current time gait may be elongated. Thisis because, if the period of the current time gait is elongated, theduration of the movement of the body horizontal position is alsoelongated, and the body horizontal position can move forward furtherproportionately.

If the desired ZMP parameter is corrected when determining anappropriate value of the body horizontal position or the like in asearching manner, the body horizontal position at the end of the currenttime gait varies in approximate proportion to the correction of thedesired ZMP. Thus, the appropriate value can be determined with areduced number of searches. On the other hand, if the free leg's centerof gravity or the period of the gait is corrected, the body horizontalposition at the end of the current time gait varies significantlynonlinearly with respect to the correction. Thus, the determination ofthe appropriate value requires more searches.

In this embodiment, the desired ZMP parameter of the current time gaitis corrected to correct the current time gait to connect the currenttime gait to the normal gait (or to bring the current time gait close tothe normal gait). According to this method, the correction amount of thedesired ZMP parameter (correction amount a in FIG. 38) may probably beexcessive. For example, in the case where a request to move at a highvelocity starting from a gait of hopping at one spot (that is, a runningrequest) is given, the desired ZMP parameter has to be significantlydisplaced rearward in the direction of travel in order to connect thehopping gait to the high-velocity normal gait (running normal gait) (orbring the hopping gait close to the high-velocity normal gait). In thiscase, a gait parameter other than the desired ZMP parameter is alsopreferably corrected as described above. However, in this case, therequest for such rapid acceleration is in itself unreasonable, andtherefore, the required value may be corrected.

When correcting the required value, for example, the normal gait thatsatisfied the request (that is, required parameters) is determinedaccording to the procedure described with reference to this embodiment,and the current time gait parameters are determined so as to connect thecurrent time gait to the normal gait. Then, it is determined whether thestability margin of the desired ZMP trajectory of the current time gaitis too small or not. If the stability margin is to small (that is, thedesired ZMP lies outside the supporting polygon or near the edge of thesupporting polygon), the request may be corrected.

Alternatively, an allowable range of the acceleration/deceleration((initial velocity of the next time gait−initial velocity of the currenttime gait)/(period of the current time gait)) of the gait may bepreviously set. In this case, when a request (that is, a requiredparameter concerning the gait period) is received, theacceleration/deceleration suitable for the request is determined, and ifthe determined acceleration/deceleration exceeds the allowable range,the request is corrected to make the acceleration/deceleration to fallwithin the allowable range.

If the floor reaction force vertical component parameter for making thebody vertical position/velocity at the end of the current time gaitagree with the body vertical position/velocity at the start of thenormal gait exceeds the capacity of the robot, the floor reaction forcevertical component parameter may be determined in such a manner thatagreement about at least the body vertical position, rather than boththe position and velocity, is achieved.

Alternatively, the floor reaction force vertical component parameter maybe determined in such a manner that the body vertical position at theend of the current time gait is lower than the body vertical position atthe start of the normal gait and the body vertical velocity at the endof the current time gait has a larger magnitude in the upward directionthan the body vertical velocity at the start of the normal gait.

Alternatively, the weighted averages of the body vertical position andbody vertical velocity at the end of the current time gait may bedetermined using a predetermined weight, and the floor reaction forcevertical component parameter may be determined in such a manner that thedetermined weighted averages agree with the weighted averages of thebody vertical position and body vertical velocity at the start of thenormal gait.

Alternatively, the floor reaction force vertical component parameter maybe determined in such a manner that the sum of the potential energy andkinetic energy of the robot at the end of the current time gait agreewith that at the start of the normal gait.

Alternatively, the process of determining the pattern of the bodyposture restoring moment ZMP-converted value (ZMPrec) in such a mannerthat the body posture angle of the current time gait comes close to thebody posture angle of the normal gait performed in step S718 in FIG. 34may be used. That is, the floor reaction force vertical componentparameter may be determined using the process of step S718 or anotherprocess of determining the body posture restoring moment ZMP-convertedvalue (ZMPrec) described later with the body posture angle and the bodyposture restoring moment ZMP-converted value being replaced with thebody vertical position and the floor reaction force vertical component,respectively.

The floor reaction force horizontal component allowable range [Fxmin,Fxmax] may be set so as to satisfy the following formulas 62 and 63.Fxmax=kmax·μ·Fz+kc·(XG−ZMPx)/(ZG−ZMPz)·FzFxmin=kmin·μ·Fz+kc·(XG−ZMPx)/(ZG−ZMPz)·Fz(kmax≧0, kmin≦0)   formula 62However, the upper limit Fxmax is set not to be larger than the value ofFxmax determined by the formula 12 on the assumption that Ka=1, and thelower limit Fxmin is set not to be smaller than the value of Fxmindetermined by the formula 12 on the assumption that Ka=1.

Here, “ZMPX” denotes the horizontal position of the desired ZMP, and“ZMPZ” denotes the vertical position of the desired ZMP.

In addition, it is assumed that “XG” and “ZG” denote the horizontalposition and vertical position, respectively, of a material particlewhich produces an approximate resultant force of the gravities andinertial forces applied on a group of material particles including atleast the body material particle. In other words, (XG, ZG) indicates theposition of a material particle which is representative of a group ofmaterial particles including at least the body material particle. Forexample, (XG, ZG) is the total center of gravity or the center ofgravity of the whole body excluding a part of a leg. Alternatively, (XG,ZG) may be the position (Xb, Xz) of the body material particle 24 m inthe dynamics model used in the above-described embodiment and shown inFIG. 10.

If it is assumed that kc=0 in the formula 62, the formula 62 is the sameas in the above-described embodiment (see the formula 12).

If the value kc is set to 1 (kc=1), and the values Fxmax and Fxmin areset to approximately 0, the vector of the desired floor reaction force(Fx, Fz) acting on the desired ZMP (ZMPX, ZMPZ) points approximately tothe position (XG, ZG). Thus, the variation of the direction of thedesired floor reaction force (in particular, the variation with a highfrequency) can be reduced.

As a result, the variation of the desired floor reaction forcehorizontal component Fx is moderated, and thus, the foot is contact withthe floor more intimately and prevented from slipping.

Since the acceleration of the body horizontal position trajectory isproportional to the value Fx, the variation of the acceleration of thebody horizontal position trajectory is also moderated, the variation ofthe body horizontal position at the end of the gait occurring when thedesired ZMP is corrected becomes linear, the convergence in searchingfor the normal gait or current time gait becomes more quick, and thus,the number of searches can be reduced.

In addition, in the case where kc=1 and kmax=kmin=0, the same behavioras that of a one-material-particle model results (in particular, if theposition (XG, ZG) is the total center of gravity). In this case, thebody horizontal position trajectory of the normal gait can be readilysearched for.

Besides, in the formula 62, the term (ZG−ZMPZ) may be substituted with apredetermined constant. This is because the value (ZG−ZMPZ) doesn't varysignificantly during walking or running (specifically, it varies by, atmost, about 10%).

In the case where kc=1, kmax=kxmin=0, the value (ZG-ZMPz) in the formula62 is substituted with a predetermined constant and the position (XG,ZG) is the total center of gravity, the same behavior as that of alinear inverted pendulum with one material particle results. Thebehavior can be solved in an analytic manner, so that the normal gaitand the current time gait can be determined without any searchingmethod. However, the angular acceleration of the body rotation modevaries more largely.

The values ΔMp, ΔFp, ΔMr and ΔFr may be determined in an analytic mannerby dynamical calculation if such a simple dynamics model as describedabove is used. However, in the case where a more general and morecomplicated dynamics model is used, these values may be determined bydetermining the floor reaction force in the case where the body isaccelerated by a small amount in the body translation mode or in thebody rotation mode, calculating the difference between this determinedfloor reaction force and the floor reaction force in the case where thebody is not accelerated, and dividing this difference by the smallamount.

Alternatively, average values for ΔMp, ΔFp, ΔMr, ΔFr and ΔMp/ΔMr for astandard gait may be previously determined and used. In this case, sincethe values ΔMp, ΔFp, ΔMr, ΔFr and ΔMp/ΔMr vary with the state of therobot (specifically, the posture and the rate of variation thereof), theprecision is slightly reduced compared to methods in which the valuesare determined for each instantaneous state. However, when a morecomplicated model than the above-described model is used, the amount ofcalculation can be reduced significantly.

In the process from step S504 to step S516 in FIG. 22 and the processfrom step S1002 to step S1014 in FIG. 37, if the floor reaction forcehorizontal component Fx falls within the allowable range with asufficient margin, this margin may be used to gradually bring theintegral value of the body posture angular acceleration β, that is, thebody posture angular velocity up to that point in time back to theoriginal value (initial state).

Specifically, in step S506 or S1004, the value (denoted by βrec) of thebody posture angular acceleration β for gradually bringing the integralvalue of the body posture angular acceleration β back to the originalvalue is determined from the integrated value of the body postureangular acceleration β up to that point in time. For example, the valueβrec may be a value obtained by multiplying the integral value of thebody posture angular acceleration β by the negative gain.

Then, the value Fxtmp is determined by the following formula 70, insteadof the formula 17.Fxtmp=ΔFp*αtmp−βrec*ΔFp*ΔMr/ΔMp+msup*d2Xsup/dt2+mswg*d2Xswg/dt2  formula 70

The second term in the right side of the formula 70 represents the floorreaction force's horizontal component caused by the acceleration(−βrec*ΔMr/ΔMp) in the body translation mode which is required to cancelthe moment (βrec*ΔMr) produced about the desired ZMP when the robotmoves in the body rotation mode with the body posture angularacceleration being βrec.

The value Fxtmp determined by the formula 70 represents the bodyhorizontal acceleration in the body translation mode which is requiredto satisfy the current time (time k) desired ZMP in the case where therobot moves in the body translation mode while moving in the bodyrotation mode with the body posture angular acceleration being βrecstarting from the last time instantaneous desired gait state (desiredgait state at the time k−1).

The following processings are the same as those in the embodimentdescribed above. Since the margin of the floor reaction force horizontalcomponent Fx can be used to restore the body posture angular velocity tosome extent in the above-described process, the variation of the bodyposture angular velocity can be further reduced.

If the body posture angle at the end of the provisional current timegait differs significantly from the body posture angle at the start ofthe normal gait when the ZMPrec pattern set in step S1016 in FIG. 37 hasa constant value of 0, the height of the trapezoidal pattern shown inFIG. 26 may be set to a value other than 0 to reduce the difference. Inthis case, however, in the subsequent step S718 shown in FIG. 34, thebody posture restoring moment ZMP-converted value pattern set in stepS1016 has to be added to the body posture restoring moment ZMP-convertedvalue pattern determined in step S718. This allows the finally resultinggait to be exactly or substantially the same as the gait resulting whena pattern having a constant value of 0 is set in step S1016.

However, it is preferable that, during the period from the start to theend of the process of the search loop of step S700 in FIG. 34, the bodyposture restoring moment ZMP-converted value pattern set in step S1016in FIG. 37 (specifically, the height of the ZMPrec pattern shown in FIG.26) is not changed. If it is changed during the process, there is apossibility that the final divergence component errq doesn't converge,and thus, the loop cannot be exited.

As a method of determining the height bcurr of the trapezoid of the bodyposture restoring moment ZMP-converted value (ZMPrec) for the currenttime gait, the following method may be used.

The body posture angle and angular velocity at the end of the currenttime gait of the ZMPrec corrected gait (see the description about stepS718 in FIG. 34) are denoted by θcurr and vθcurr, respectively, and thedifferences between the body posture angle and angular velocity at theend of the current time gait and the body posture angle and angularvelocity at the start of the normal gait are denoted by Δθcerr andΔvθcerr, respectively.

Assuming that the gait period is an interval, the differences θerr andvθerr between the body posture angle and angular velocity at the end ofthe provisional current time gait and the body posture angle and angularvelocity at the start of the normal gait are the last time states, thevalue bcuur is an input, and the values Δθcerr and Δvθcerr are thecurrent time states, a characteristic equation in a discrete system isestablished. Then, a feedback rule may be established using the moderncontrol theory or the like in such a manner that the values Δθcerr andΔvθcerr converge to 0, and the value bcurr may be determined based onthe feedback rule.

The ZMPrec for the current time gait and/or the normal gait may not havea trapezoidal pattern. The ZMPrec value for each instant may bedetermined using a state feedback rule or the like, based on thedifference between the desired body posture angle and angular velocityand the reference body posture angle and angular velocity or the like,in such a manner that the difference converges to 0.

The ZMPrec for the current time gait may not have a trapezoidal pattern.The ZMPrec value for each instant may be determined using a statefeedback rule or the like, based on the desired body posture angle andangular velocity of the current time gait, in such a manner that thebody posture angle and the angular velocity come close to the bodyposture angle and angular velocity at the start of the first turninggait.

Now, generation of a walking gait of the robot 1 will be described. Thewalking gait is a gait including no floating period in which one-legsupporting periods and two-leg supporting periods are repeatedalternately.

When generating a walking gait, the following process is conducted insteps S106 and S606. Specifically, the floor reaction force verticalcomponent trajectory is determined in such a manner that acharacteristic quantity, such as phase or amplitude, of the bodyvertical position trajectory (which is determined using the body heightdetermination method disclosed in Japanese Patent Laid-Open No. 10-86080by the applicants) is satisfied as fully as possible, the body verticalposition trajectory being determined based on a geometrical condition(geometrical limitation) concerning at least displacement of a joint ofeach leg, such as one concerning an appropriate knee bending angle.

Thus, the algorithms for generating a walking gait and a running gaitcan have a common essential part, and shifting from the walking gait tothe running gait or from the running gait to the walking gait can beconducted.

Now, the process will be described with reference to FIG. 43. First, instep S1300, using the body height determination method previouslyproposed by the applicants in Japanese Patent Laid-Open No. 10-86080 orthe like, the body vertical position trajectory which satisfies apredetermined geometrical limitation concerning at least displacement ofa joint of each leg 2 is determined. In the following, this is referredto as a reference body vertical position trajectory. More specifically,first, based on the foot trajectory parameters, the desired ZMPtrajectory parameters or the like determined in accordance with therequired parameters, the body horizontal position trajectory isdetermined using the first embodiment disclosed in Japanese PatentApplication No. 2000-352011 previously filed by the applicants. In thiscase, the body horizontal position trajectory is determined in such amanner that the floor reaction force's vertical component agrees withthe weight of the robot 1, and the floor reaction force's moment aboutthe desired ZMP has a horizontal component of 0 assuming that the bodyvertical position has a predetermined constant value. In addition, thebody posture trajectory may be a trajectory of a certain posture(vertical posture or the like).

Then, using the body height determination method previously proposed bythe applicants (in Japanese Patent Laid-Open No. 10-86080, morespecifically, the method shown in FIG. 6 of this document or the like),the body vertical position trajectory is calculated based on the foottrajectory determined by the foot trajectory parameters, and the bodyhorizontal position trajectory and body posture trajectory thusdetermined, and the calculated body vertical position trajectory isassumed as the reference body vertical position trajectory.

Then, the process proceeds to step S1302, where a characteristicquantity, such as amplitude or phase, of the reference body verticalposition trajectory is calculated (extracted) in order to determine thefloor reaction force vertical component trajectory which allowsgeneration of a desired body vertical position trajectory resembling thereference body vertical position trajectory as closely as possible. Forexample, the amplitude of the reference body vertical positiontrajectory (that is, the difference between the minimum value and themaximum value thereof) is calculated as a characteristic quantity.

Next, the process proceeds to step S1304, where floor reaction force'svertical component trajectory parameters (times and values of a floorreaction force's vertical component at apexes) are determined in such amanner that a body vertical position trajectory, which is generated onthe basis of floor reaction force's vertical component trajectoryparameters, satisfies the characteristic quantity as much as possible(in such a manner that the body vertical position trajectory has apattern similar to the reference body vertical position trajectory asmuch as possible). More specifically, in the case of a waling gait, afirst turning gait and a second turning gait of a normal gait and afloor reaction force's vertical component trajectory of a current timegait are set, for example, in a polygonal pattern as shown in FIG. 42.That is, the floor reaction force's vertical component trajectory forthe walking gait is set to have a trapezoidal shape protruding in thedirection of the floor reaction force's vertical component increasing(protruding upward) during the two-leg supporting period and set to havea trapezoidal shape protruding in the direction of the floor reactionforce's vertical component decreasing (protruding downward) during theone-leg supporting period. Then, floor reaction force's verticalcomponent trajectory parameters, for example, heights C1, C2 of twotrapezoids of the floor reaction force's vertical component trajectoryare determined (in this example, times of apexes of the floor reactionforce's vertical component trajectory are determined according torequired parameters relating to a gait period) in such a manner that adifference between a maximum value and a minimum value of a bodyvertical position trajectory corresponding to a total center-of-gravityvertical position trajectory of the robot 1, which is obtained by secondorder integral of the floor reaction force's vertical componenttrajectory from a gait initial period (start time of the both-legsupporting period) to an end (end time of the one-leg supportingperiod), agrees with the characteristic quantity.

However, parameters of the floor reaction force's vertical componenttrajectory of the normal gait are determined so as to satisfy thefollowing condition as describe above. Condition) An average value ofthe floor reaction force's vertical component trajectory in an entireperiod of the normal gait (periods of the first and second turninggaits) is made to agree with the weight of the robot. That is, anaverage value of the floor reaction force's vertical component is madeequal in magnitude and opposite in direction to gravity applied to therobot.

In addition, the parameters of the floor reaction force's verticalcomponent trajectory of the current time gait are determined in such amanner that the body (total center-center-of-gravity) vertical positiontrajectory is seamlessly connected to or comes close to the normal gait,as described above.

By the processing described above, the desired floor reaction force'svertical component trajectory (parameters defining the same) in thewalking gait is determined. Gait generation process other than thedetermination process for the desired floor reaction force's verticalcomponent trajectory described above may be identical with theembodiment related to the walking gait described above.

A calculation amount required for determining the reference bodyvertical position trajectory is relatively large as described above.Thus, it is also possible that a map, which represents a relationshipbetween movement parameters (foot trajectory parameters, etc.) of thenormal gait and characteristic quantities (amplitude, etc.) of the body(total center-of-gravity) vertical position trajectory, is created andstored in advance, and a characteristic quantity is determined from givenormal gait parameters with reference to the map.

Alternatively, it is also possible that a map, which represents arelationship between movement parameters of the normal gait in the casewhere a characteristic quantity of the body (total center-of-gravity)vertical position trajectory generated from the floor reaction force'svertical component substantially agrees with a characteristic quantityof the reference body vertical position trajectory and floor reactionforce's vertical component trajectory parameters, is created and storedin advance, and the floor reaction force's vertical component trajectoryparameters is determined from give normal gait parameters with referenceto the map.

Note that, basically, the characteristic quantity only has to be acharacteristic quantity that represents characteristics of a shape ofthe reference body vertical position trajectory based upon thegeometrical limitation condition. Other than amplitude, a phase, and thelike of the reference body vertical position trajectory, a frequencycomponent or the like (e.g., an amplitude of a basic frequencycomponent, etc.) may be used as the characteristic quantity.

Moreover, although the characteristic quantity of the reference bodyvertical position trajectory for one step is used in the above-mentionedexample, an initial state (position, velocity) of the reference bodyvertical position trajectory may be used as a characteristic quantity todetermine the floor reaction force's vertical component trajectoryparameters as described below.

That is, as shown in FIG. 44, first, in step S1400, using the bodyheight determination method proposed by the applicant previously(Japanese Patent Application Laid-Open No. 10-86080) or the like, areference body vertical position at an initial time of a gait and areference body vertical position after Δt seconds (after a controlcycle) are determined on the basis of at least the geometricallimitation conditions, and an initial reference body vertical velocityis calculated on the basis of a difference between the reference bodyvertical position at an initial time of the gait and a reference bodyvertical position after Δt seconds. Note that the reference bodyvertical position at an initial time and a reference body verticalposition after Δt seconds can be determined if, for example, theprocessing of step S1300 in FIG. 43 is executed from the initial timeuntil Δt seconds elapses.

Subsequently, the process proceeds to step S1402, where an initialreference total center-of-gravity vertical velocity is calculated usinga robot geometric model (e.g., a model found by differentiating bothside of the formula 04) on the basis of a foot position trajectorydetermined by the initial reference body vertical velocity and the foottrajectory parameters.

Finally, the process proceeds to step S1404, where floor reactionforce's vertical component trajectory parameters are determined in sucha manner that an initial velocity of the total center-of-gravityvertical position trajectory generated from the floor reaction force'svertical component trajectory agrees with the initial reference totalcenter-of-gravity velocity determined as described above. Note that, inthis case, again, the floor reaction force's vertical componenttrajectory parameters are determined in such a manner that not only thecondition of the initial velocity but also the above-describedconditions related to the normal gait and the current time gait (theconditions described in relation to the processing in FIG. 43) aresatisfied.

In addition, if the processing in FIG. 44 is performed in step S106 inFIG. 14, since an initial body vertical velocity Vzs (at a time Ts) isdetermined at that point, naturally, the processing for determining thebody vertical velocity Vzs can be omitted in step S206 in FIG. 19.

It is also possible that, in the case where a walking gait is generated,using the body height determination method proposed by the applicantpreviously (Japanese Patent Application Laid-Open No. 10-86080) or thelike, a body vertical position is determined on the basis of at leastthe geometrical limitation conditions and, in the case where a runninggait is generated, the body vertical position is determined from thefloor reaction force's vertical component as described in steps S906,S908 in FIG. 36. In this case, it is preferable that a final bodyvertical position in a gait at the time when the gait shifts fromwalking to running or from running to walking is determined bysynthesizing a body vertical position Zg for walking, which isdetermined on the basis of the geometrical limitation condition, and abody vertical position Zf for running, which is determined dynamicallyfrom the floor reaction force's vertical component More specifically,for example, as indicted by the following formula 71, a final bodyvertical position Z is determined according to a weighted average ofthose body vertical positions Zg and Zf. In this case, a weight w isgradually changed from 1 to 0 or from 0 to 1.

Consequently, the body vertical position trajectory during the time whenthe gait shifts from walking to running can be changed smoothly.body vertical position Z=(1−w)*Zg+w*Zf   formula 71

Specific processes will be described with reference to FIG. 45. First,in step S1500, as described in the above embodiment (see step S908 inFIG. 36), the body vertical position Zf satisfying a totalcenter-of-gravity vertical position trajectory, which is determinedaccording to a desired floor reaction force's vertical componenttrajectory, is calculated. Subsequently, the process proceeds to stepS1502, the body vertical position Zg, which is determined on the basisof at least the geometrical limitation condition concerning displacementof the joints (knee joints) of the respective legs 2, is generated usingthe body height determination method proposed by the applicantpreviously or the like.

Then, the process proceeds to step S1504, where the weight w isdetermined according to a time of a gait. For example, the weight w ofthe formula 71 is determined so as to change gradually from 0 to 1 orfrom 1 to 0 from the start to the end of the gait. In this case, theweight w is determined in such a manner that w is changed from 0 to 1 atthe time of shift from walking to running and is changed from 1 to 0 atthe time of shift from running to walking. Note that it is advisable toalso set a variation rate of the weight w (a first order timedifferential of a weight) so as to change continuously. Moreover, it isadvisable to also set a variation rate of the variation rate of theweight w (a second order time differential of a weight) so as to changecontinuously. Consequently, a body vertical position trajectory to befinally generated becomes smooth.

Finally, the process proceeds to step S1506, where a final body verticalposition is determined according to the formula 71.

Note that the weight w may take an intermediate value between 0 and 1not only at the time when a gait shifts from walking to running or fromrunning to walking but also at other times. In addition, the shift fromwalking to running or from running to walking is not required to beperformed in one gait but may be performed in plural gaits.

In gait generation at the time of movement on a slope (when the robot 1is moved on an inclined floor surface), instead of the allowable rangeof the floor reaction force's horizontal component and the allowablerange of the horizontal component of the total center-of-gravityacceleration, the allowable range of a floor-surface-parallel component(component parallel to the floor surface) of the translation floorreaction force, that is, the allowable range of the friction force, orthe allowable range of a component parallel to the floor surface of thetotal center-of-gravity acceleration (which is proportional to thefriction force) may be set. For example, as for a case of setting theallowable range of the floor-surface-parallel component of thetranslation floor reaction force (friction force) (the same holds truefor a case of setting the allowable range of the floor-surface-parallelcomponent of the total center-of-gravity acceleration), assuming thatthe inclination angle of the floor surface with respect to thehorizontal surface is denoted by θf (where θf is positive when thesurface is inclined downwardly in the travel direction of the robot 1),the friction force is represented by the following formula 72. Thus, inthe case where a gait is generated according to the same algorithm asthat in the embodiments described above, it is advisable to convert thefriction force allowable range into the floor reaction force'shorizontal component allowable range using the formula 72 to thereby setthe floor reaction force's horizontal component allowable range. Notethat, in this case, as the floor reaction force's vertical component ina formula 72, the desired floor reaction force's vertical component onlyhas to be used.friction force=floor reaction force's horizontal component*cos(θf)−floor reaction force's vertical component*sin (θf)   formula 72

Determination of parameters of the current time gait may be performedagain in the processing of generating the current time gait as describedin Japanese Patent Application No. 2000-352011 filed by the applicantother than being performed at the point when the last time gait iscompleted as in the above-described embodiments. This is because thisprocess increases the amount of calculation but, when there is a changein a request for a gait, can instantaneously cope with the change.

In addition, it is also possible that, in the case where the currenttime control cycle is not enough for correction of a gait (which meanscurrent time gait parameters are determined again), a gait not correctedor provisionally corrected (a gait that is in the course of search anddoes not satisfy a search completion condition (deviation from gaitboundary requirements falls within an allowable value) completely) isoutputted for the time being, and the gait is changed to an appropriatecorrected gait (not provisional) by the next time control cycle or bythe completion of plural control cycles. Since the corrected desired ZMPand desired floor reaction force's vertical component trajectory arecontinuous, and these never change suddenly after a short time, there isalmost no problem except that only the desired ZMP trajectory and thedesired floor reaction force's vertical component trajectory arezigzagged slightly.

Instead of the arm swing movement that cancels the spinning force instep S032 in FIG. 12, a movement for rotating (twisting) the body 24about a trunk axis (or a vertical axis) thereof may be performed.Alternatively, the arm swing movement and the movement for rotating(twisting) the body 24 about the trunk axis (or the vertical axis)thereof may be combined.

When the body vertical position satisfying the total center-of-gravityvertical position velocity is determined in step S408 in FIG. 21 andstep S908 in FIG. 36, instead of determining the body vertical positionin an analytical manner using the formula 04 or the like as describedabove, the body vertical position may be determined according to anothermethod 1 or 2 described below.

Another Method 1:

FIG. 46 shows a calculation process flowchart of another method 1.

First, in step S1100, a total center-of-gravity verticalposition/velocity is calculated using the dynamics model on the basis ofa last time instantaneous desired gait state (the desired gait statedetermined at the time k−1) or the like. The total center-of-gravityvertical position/velocity calculated using the dynamics model ishereinafter referred to as a model total center-of-gravity verticalposition/velocity. That is, in step S1100, the last time model totalcenter-of-gravity vertical position/velocity is calculated. Note that,as the dynamics model, for example, a multi-mass model or the like asshown in FIG. 11 only has to be used.

Subsequently, the process proceeds to step S1102, where a differencebetween the last time model total center-of-gravity verticalposition/velocity determined as described above and the totalcenter-of-gravity vertical position/velocity calculated in step S406 inFIG. 21 or step S906 in FIG. 36, that is, the total center-of-gravityvertical position/velocity satisfying the current time value (value atthe time k) of the desired floor reaction force's vertical component(both a difference of a position and a difference of a velocity; thisdifference will be hereinafter referred to as a center-of-gravityvertical position/velocity deviation) is determined. That is, thecenter-of-gravity position/velocity deviation is determined according tothe following formula 80.center-of-gravity vertical position and velocity deviation=last timemodel total center-of-gravity vertical position and velocity−totalcenter-of-gravity direction position and velocity satisfying the desiredfloor reaction force's vertical component   formula 80

Subsequently, the process proceeds to step S1104, where a current timebody vertical position (a current time value of the body verticalposition) is determined on the basis of at least the center-of-gravityvertical direction deviation and the last time body vertical position(the body vertical position determined at the time k−1) in such a mannerthat the model total center-of-gravity vertical position/velocityfollows the total center-of-gravity vertical position/velocitysatisfying the desired floor reaction force's vertical component. Forexample, the current time body vertical position is determined accordingto the following formula.

$\begin{matrix}{{{current}\mspace{14mu}{time}\mspace{14mu}{body}\mspace{14mu}{vertical}\mspace{14mu}{position}} = {{{last}\mspace{14mu}{time}\mspace{14mu}{body}\mspace{14mu}{vertical}\mspace{14mu}{position}} + {{Kgz}*{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}\mspace{14mu}{deviation}} + {{Kgvz}*{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{deviation}}}} & {{formula}\mspace{14mu} 81}\end{matrix}$Here, “Kgz” and “Kgvz” denote gains.

Kgvz may be 0. In this case, it is unnecessary to calculate a totalcenter-of-gravity vertical velocity and a center-of-gravity verticaldirection velocity deviation that satisfy the model totalcenter-of-gravity vertical velocity and the desired floor reactionforce's vertical component.

The current time body vertical position is calculated as describedabove. In this case, when the formula 81 is used, the current timevertical position is calculated according to the center-of-gravityvertical position deviation and the center-of-gravity vertical velocitydeviation.

In addition, it is also possible that, in order to determined thecurrent time body vertical position, the current time body verticalposition is determined by adding a component (feed-forward component)corresponding to the body vertical position determined using the modelof the robot 1 (e.g., a three-material-particle model obtained byexcluding the flywheel FH from the model of FIG. 10) to the last timebody vertical position, other than the component corresponding to thecenter-of-gravity vertical position deviation and the componentcorresponding to the center-of-gravity vertical velocity deviation. Inthis case, a provisional body vertical position (which is referred to asan FF body vertical position here) is determined using, for example, thethree-material-particle model from the total center-of-gravity verticalposition velocity calculated in step S406 in FIG. 21 or step S906 inFIG. 36, that is, the total center-of-gravity vertical position velocitysatisfying the current time value (the value at the time k) of thedesired floor reaction force's vertical component and the current timevalue (the value at the time k) of the desired feet positions/posturescalculated in step S404 in FIG. 21 or step S904 in FIG. 36. Note that,in the case the body vertical position is determined using the model ofFIG. 10 in step S408 in FIG. 21 or step S908 in FIG. 36 as describedabove, the body vertical position only has to be used directly as the FFbody vertical position. Then, with a value, which is obtained bymultiplying the FF body vertical position determined as described abovewith an appropriate gain, is further added to the right side of theformula 81 as a feed-forward component, whereby the current time bodyvertical position is determined. That is, the current time body verticalposition is determined by correcting the last time body verticalposition according to the center-of-gravity vertical position deviationand the center-of-gravity vertical velocity deviation (thecenter-of-gravity vertical velocity deviation may be omitted) and the FFbody vertical position. This allows fluctuation of the current time bodyvertical position, which is determined finally, to be controlled. Notethat it is preferable that the model of the robot 1, which is used fordetermining the last time body vertical position with this method, is amore precise model.

Another Method 2:

In addition, the current time body vertical position may be determinedaccording to another method 2 using a repetitious searching method asdescribed below.

FIG. 47 shows a calculation process flowchart of the method.

First, in step S1200, a body vertical position/velocity (more precisely,a candidate of a current time value of the body verticalposition/velocity) is determined provisionally. For example, a bodyvertical position/velocity (last time value) of a last time desired gaitinstantaneous value is determined provisionally as a candidate value ofthe body vertical position/velocity. Alternatively, a value, which isfound by adding a product of the body vertical velocity of the last timedesired gait instantaneous value and a control cycle Δt to the last timevalue of the body vertical position, may be determined provisionally asthe candidate value of the body vertical position.

Subsequently, through step S1202, the process proceeds to step S1204,where a current time model total center-of-gravity verticalposition/velocity is calculated from the present value (presentprovisionally determined value) of the body vertical position velocity(candidate), the current time value of the desired feetpositions/postures determined as described above, the desired bodyposture at the time (k−Δk) (or current time value of the reference bodyposture determined as described above), the current time value of thedesired arm posture determined as described above, the body horizontalposition at the time (k−Δk), and a posture state of the robot 1determined from change rates of these values. Note that the last timevalue is used for a part of variables used in the calculation of thecurrent time mode total center-of-gravity vertical position/velocity.

Subsequently, the process proceeds to step S1206, where acenter-of-gravity vertical direction position/velocity deviation iscalculated according to the following formula 82.center-of-gravity vertical position and velocity deviation=current timemodel total center-of-gravity vertical position and velocity−totalcenter-of-gravity vertical position satisfying the desired floorreaction force's vertical component  formula 82

Subsequently, the process proceeds to step S1208, where, if thecenter-of-gravity vertical position deviation determined according tothe formula 82 is within a predetermined allowable range, the finallydetermined body vertical position (present value) is determined as thecurrent time value of the body vertical position (current time bodyvertical position), and the processing for determining the current timebody vertical position is completed. In addition, if thecenter-of-gravity vertical position deviation is not within thepredetermined allowable range in the judgment of step S1208, the processproceeds to step S1210, where a next candidate of the body verticalposition is determined according to the following formula.

$\begin{matrix}{{{next}\mspace{14mu}{candidate}\mspace{14mu}{of}\mspace{14mu}{body}\mspace{14mu}{vertical}\mspace{14mu}{position}} = {{{body}\mspace{14mu}{vertical}\mspace{14mu}{position}} + {{Kgz}*{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{position}\mspace{14mu}{deviation}} + {{Kgvz}*{center}\text{-}{of}\text{-}{gravity}\mspace{14mu}{vertical}\mspace{14mu}{velocity}\mspace{14mu}{deviation}}}} & {{formula}\mspace{14mu} 83}\end{matrix}$Subsequently, the process proceeds to step S1212, where the nextcandidate of the body vertical position is set as the body verticalposition again (the candidate of the body vertical position is updated).Then, the process proceeds to step S1204 again. Then, a current timemodel total center-of-gravity vertical position/velocity is determinedon the basis of the new candidate of the body vertical position.Thereafter, the above-described process is repeated until thecenter-of-gravity vertical direction position/velocity deviation fallswithin the predetermined allowable range.

These methods 1 and 2 determine the body vertical position such that themodel total center-of-gravity vertical position follows or substantiallyagrees with the total center-of-gravity vertical position calculated instep S406 in FIG. 21 or in step S908 in FIG. 36, that is, a totalcenter-of-gravity vertical position that is obtained by second orderintegration of a value found by dividing the current time value of thedesired floor reaction force's vertical component by a total mass.

Instead of the above, it is also possible that a body vertical velocityis determined according to the same method as the method 1 or the method2 in such a manner that the model total center-of-gravity verticalvelocity follows or substantially agrees with a total center-of-gravityvertical velocity that is obtained by first order integration of a valuefound by dividing the current time value of the desired floor reactionforce's vertical component by a total mass, a body vertical position isdetermined by first order integration of the body vertical velocity.

Alternatively, it is also possible that a body vertical acceleration isdetermined according to the same method as the method 1 or the method 2in such a manner that a model total center-of-gravity verticalacceleration follows or substantially agrees with a value that is foundby dividing the current time value of the desired floor reaction force'svertical component by a total mass, the body vertical position isdetermined by second order integration of the body verticalacceleration.

However, although an instantaneous dynamic error is small compared withthe methods 1 and 2, even if the model total center-of-gravity verticalposition is deviated from the total center-of-gravity vertical position,which is obtained by second order integration of the value found bydividing the current time value of the desired floor reaction force'svertical component by the total mass, due to an integration error, sincean action for making the deviation to converge to 0 does not work, adynamic accuracy of a gait tends to fall in a long term.

In other words, in the methods 1 and 2, since an instantaneous dynamicerror is slightly large but a long-term dynamic error is small,stability of a posture of a robot is improved.

INDUSTRIAL APPLICABILITY

As described above, the present invention is effective in generating agait with which a legged mobile robot, such as a two-legged mobilerobot, can move smoothly in a variety of gait modes.

1. A gait generation device for generating a desired gait for a leggedmobile robot that moves by operating a plurality of legs extending froma body, wherein said desired gait is generated so as to satisfy apredetermined dynamical equilibrium condition concerning the resultantforce of gravity and an inertial force applied to the robot using adynamics model which describes a relationship among at least ahorizontal translation movement of said body, a posture varying movementin which the posture of a predetermined part of the robot is variedwhile keeping the center of gravity of said robot substantiallyunchanged and floor reaction forces generated due to the movements andis defined on the assumption that a total floor reaction force generateddue to a combined movement of the movements is represented as a linearcoupling of the floor reaction forces associated with each of themovements.
 2. The gait generation device for a legged mobile robotaccording to claim 1, wherein said predetermined part is the body of therobot.
 3. The gait generation device for a legged mobile robot accordingto claim 1, wherein said dynamics model represents said horizontaltranslation movement of the body as a horizontal translation movement ofa material particle and said posture varying movement of thepredetermined part as a rotational movement of a flywheel.
 4. A gaitgeneration device for generating a desired gait for a legged mobilerobot that moves by operating a plurality of legs extending from a body,wherein said desired gait is generated so as to satisfy a predetermineddynamical equilibrium condition concerning the resultant force ofgravity and an inertial force applied to the robot using a dynamicsmodel which describes a relationship among at least a movement of an endportion of each leg, a horizontal translation movement of the body, aposture varying movement in which the posture of a predetermined part ofthe robot is varied while keeping the center of gravity of said robotsubstantially unchanged and floor reaction forces generated due to themovements and is defined on the assumption that a total floor reactionforce generated due to a combined movement of the movements isrepresented as a linear coupling of the floor reaction forces associatedwith each of the movements.
 5. The gait generation device for a leggedmobile robot according to claim 4, wherein said dynamics modelrepresents said movement of the end portion of each leg as a movement ofa material particle corresponding to the leg, said horizontaltranslation movement of the body as a horizontal translation movement ofa material particle corresponding to the body and said posture varyingmovement of the predetermined part as a rotational movement of aflywheel.
 6. The gait generation device for a legged mobile robotaccording to claim 4, wherein the gait generation device furthercomprises means for setting a desired ZMP of said robot, wherein saiddynamical equilibrium condition is a condition that a moment producedabout said desired ZMP by a movement with said desired gait issubstantially
 0. 7. The gait generation device for a legged mobile robotaccording to claim 4, wherein said predetermined part is the body of therobot.
 8. A gait generation device for generating a desired gait for alegged mobile robot that moves by operating a plurality of legsextending from a body, wherein said desired gait is generated so as tosatisfy a predetermined dynamical equilibrium condition concerning theresultant force of gravity and an inertial force applied to the robotusing a dynamics model which describes a relationship among at least amovement of an end portion of each leg, a horizontal translationmovement of the body, a vertical translation movement of the body, aposture varying movement in which the posture of a predetermined part ofthe robot is varied while keeping the center of gravity of said robotsubstantially unchanged and floor reaction forces generated due to themovements and is defined on the assumption that a total floor reactionforce generated due to a combined movement of the movements isrepresented as a linear coupling of the floor reaction forces associatedwith each of the movements.
 9. The gait generation device for a leggedmobile robot according to claim 8, wherein said dynamics modelrepresents said movement of the end portion of each leg as a movement ofa material particle corresponding to the leg, said horizontaltranslation movement of the body as a horizontal translation movement ofa material particle corresponding to the body, said vertical translationmovement of the body as a vertical translation movement of the materialparticle corresponding to the body and said posture varying movement ofthe predetermined part as a rotational movement of a flywheel.
 10. Thegait generation device for a legged mobile robot according to claim 8,wherein the gait generation device further comprises means for setting adesired ZMP of said robot, wherein said dynamical equilibrium conditionis a condition that a moment produced about said desired ZMP by amovement with said desired gait is substantially
 0. 11. The gaitgeneration device for a legged mobile robot according to claim 8,wherein said predetermined part is the body of the robot.
 12. The gaitgeneration device for a legged mobile robot according to claim 1,wherein the gait generation device further comprises means for setting adesired ZMP of said robot, wherein said dynamical equilibrium conditionis a condition that a moment produced about said desired ZMP by amovement with said desired gait is substantially 0.